AR# 54128


Are Nested interrupts supported on the Zynq interrupt controller (GIC)?


Are Nested Interrupts supported on the Zynq interrupt controller (GIC)?


Nested Interrupts is currently supported in the GIC Interrupt Controller on the Zynq SoC in version 2013.4/14.7. If you are using this version, then proceed to step 3.

If you are using an older version and would like to add nested interrupt capability, then unzip the ZIP file that is attached at the end of this answer record) into your local EDK install directory:

Copy standalone_v3_10_a from to:


Copy scugic_v1_04_a from to:

Then follow these two steps:

  1. Create BSP

    Create a Board Support Package

    In SDK, File -> New -> Board Support Package and select the standalone from the dropdown

    Configure the BSP to match your application settings, and make sure that the ps7_scugic_0 driver version is set to 1.04.a:
  2. Create, or Link your existing application to the newly created BSP.

    To link a pre-existing application, right-click on the application, select Properties -> Project References and untick the old BSP and add the newly created BSP allowing Nested Interrupts

  3. Add Nested Interrupt capability to your application

    To allow Nested Interrupts in your application, add the function below during the GIC initialization before XilExceptionInit is called:
    XScuGic_CPUWriteReg(IntcInstancePtr, XSCGIC_BIN_PT_OFFSET,0x03);

    In the Interrupt handler, the user must ensure that the source of the current interrupt is cleared and enable Nested Interrupts using the function:

    After calling this macro, Nested Interrupts will be allowed. However, only interrupts with higher group priority than the existing interrupt being processed.

    The user must include the header file:
    #include "xil_exception.h"

    Similarily, before exiting the Interrupt handler, the Nested Interrupts must be disabled:

Note: Added to this AR there is a nested_interrupt_demo.c that can be used to verify the nested interrupts. To test this create a simple zc702 with two timers on the Zynq SoC Processor Subsystem.

Export to SDK, follow the instructions above. Create an Empty application and import the nested_interrupt_demo.c.


文件名 文件大小 File Type 492 KB ZIP
AR# 54128
日期 01/10/2014
状态 Active
Type 综合文章
Tools More Less
People Also Viewed