Interrupt Example - 2022.2 English

Vitis Networking P4 User Guide (UG1308)

Document ID
2022.2 English

This example summarizes Target and Interrupt API functions to control and monitor the ECC interrupts for the table present in the FiveTuple example. This example C program is provided at the following location:


This program demonstrates target and interrupt driver function calls to achieve the following functionality:
  • Initialize the driver using XilVitisNetP4TargetInit()
  • Obtain the context for the interrupt driver using XilVitisNetP4TargetGetInterruptDrv()
  • Obtain the P4 element ID for the “FiveTuple” table using XilVitisNetP4TargetGetTableElementIdByName()
  • Enable both single and double bit ECC error interrupts using XilVitisNetP4TargetInterruptEnableElementEccErrorById()
  • Read interrupt status to determine if either a single or double bit ECC error interrupt has occurred using XilVitisNetP4TargetInterruptGetElementEccErrorStatusById()
  • Clear the single or double bit ECC error interrupts if present using XilVitisNetP4TargetInterruptClearElementEccErrorStatusById()
  • Disable the single bit ECC error interrupt using XilVitisNetP4TargetInterruptDisableElementEccErrorById()
  • Exit driver using XilVitisNetP4TargetExit()