XilinxProcessorIPLib/drivers/v_sditx/src/xv_sditx_intr.c
void XV_SdiTx_IntrHandler(void *InstancePtr)
{
	u32 ActiveIntr;
	u32 Mask;

	XV_SdiTx *SdiTxPtr = (XV_SdiTx *)InstancePtr;

	/* Verify arguments */
	Xil_AssertVoid(SdiTxPtr != NULL);
	Xil_AssertVoid(SdiTxPtr->IsReady == XIL_COMPONENT_IS_READY);

	/* Get Active interrupts */
	ActiveIntr = XV_SdiTx_GetIntrStatus(SdiTxPtr);

	/* Read ISR register  for Gtresetdone*/
	Mask = ActiveIntr & XV_SDITX_ISR_GTTX_RSTDONE_MASK;

	/* Check for GTTX_RSTDONE IRQ flag set */
	if (Mask) {

		/* Jump to GT reset done interrupt handler */
		if (XV_SdiTx_ReadReg(SdiTxPtr->Config.BaseAddress,
					XV_SDITX_SB_TX_STS_TDATA_OFFSET) &
					XV_SDITX_SB_TX_STS_TDATA_GT_TX_RESETDONE_MASK) {
			SdiTx_GtTxRstDoneIntrHandler(SdiTxPtr);
		}

		/* Clear handled interrupt(s) */
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}

	/* Read ISR register  for OVERRFLOW*/
	Mask = ActiveIntr & XV_SDITX_ISR_OVERFLOW_MASK;

	/* Check for OVERFLOW IRQ flag set */
	if (Mask) {

		/* Jump to OVERFLOW interrupt handler */
		SdiTx_OverFlowIntrHandler(SdiTxPtr);

		/* Clear handled interrupt(s) */
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}

	/* Read ISR register  for UNDERFLOW*/
	Mask = ActiveIntr & XV_SDITX_ISR_UNDERFLOW_MASK;

	/* Check for UNDERFLOW IRQ flag set */
	if (Mask) {

		/* Jump to UNDERFLOW interrupt handler */
		SdiTx_UnderFlowIntrHandler(SdiTxPtr);

		/* Clear handled interrupt(s) */
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}

	/* Read ISR register  for CE_ALIGN_ERROR*/
	Mask = ActiveIntr & XV_SDITX_ISR_TX_CE_ALIGN_ERR_MASK;

	/* Check for CE_ALIGN_ERROR IRQ flag set */
	if (Mask) {

		/* Jump to CE_ALIGN_ERROR interrupt handler */
		SdiTx_CeAlignErrIntrHandler(SdiTxPtr);

		/* Clear handled interrupt(s) */
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}

	/* Read ISR register  for Axi4S Video lock*/
	Mask = ActiveIntr & XV_SDITX_ISR_AXI4S_VID_LOCK_MASK;

	/* Check for Axi4s Video lock IRQ flag set */
	if (Mask) {

		/* Jump to Axi4s video lock interrupt handler */
		SdiTx_Axi4sVidLockIntrHandler(SdiTxPtr);

		/* Clear handled interrupt(s) */
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
}
/*****************************************************************************/
/**
*
* This function is the interrupt handler for the SDI TX driver.
*
* This handler reads the pending interrupt for GT reset done interrupt from
* Tx IP, determines the source of the interrupts, clears the
* interrupts and calls callbacks accordingly.
*
* The application is responsible for connecting this function to the interrupt
* system. Application beyond this driver is also responsible for providing
* callbacks to handle interrupts and installing the callbacks using
* XV_SdiTx_SetCallback() during initialization phase. An example delivered
* with this driver demonstrates how this could be done.
*
* @param    InstancePtr is a pointer to the XV_SdiTx instance that just
*       interrupted.
*
* @return   None.
*
* @note     None.
*
******************************************************************************/
This function is the interrupt handler for the SDI TX driver.
This handler reads the pending interrupt for GT reset done interrupt from
Tx IP, determines the source of the interrupts, clears the
interrupts and calls callbacks accordingly.

The application is responsible for connecting this function to the interrupt
system. Application beyond this driver is also responsible for providing
callbacks to handle interrupts and installing the callbacks using
XV_SdiTx_SetCallback() during initialization phase. An example delivered
with this driver demonstrates how this could be done.
This function is the interrupt handler for the SDI TX driver . This handler reads the pending interrupt for GT reset done interrupt from Tx IP determines the source of the interrupts clears the interrupts and calls callbacks accordingly . The application is responsible for connecting this function to the interrupt system . Application beyond this driver is also responsible for providing callbacks to handle interrupts and installing the callbacks using XV_SdiTx_SetCallback () during initialization phase . An example delivered with this driver demonstrates how this could be done .
void XV_SdiTx_IntrHandler(void *InstancePtr)
{
	u32 ActiveIntr;
	u32 Mask;
	XV_SdiTx *SdiTxPtr = (XV_SdiTx *)InstancePtr;
	Xil_AssertVoid(SdiTxPtr != NULL);
	Xil_AssertVoid(SdiTxPtr->IsReady == XIL_COMPONENT_IS_READY);
	ActiveIntr = XV_SdiTx_GetIntrStatus(SdiTxPtr);
	Mask = ActiveIntr & XV_SDITX_ISR_GTTX_RSTDONE_MASK;
	if (Mask) {
		if (XV_SdiTx_ReadReg(SdiTxPtr->Config.BaseAddress,
					XV_SDITX_SB_TX_STS_TDATA_OFFSET) &
					XV_SDITX_SB_TX_STS_TDATA_GT_TX_RESETDONE_MASK) {
			SdiTx_GtTxRstDoneIntrHandler(SdiTxPtr);
		}
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
	Mask = ActiveIntr & XV_SDITX_ISR_OVERFLOW_MASK;
	if (Mask) {
		SdiTx_OverFlowIntrHandler(SdiTxPtr);
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
	Mask = ActiveIntr & XV_SDITX_ISR_UNDERFLOW_MASK;
	if (Mask) {
		SdiTx_UnderFlowIntrHandler(SdiTxPtr);
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
	Mask = ActiveIntr & XV_SDITX_ISR_TX_CE_ALIGN_ERR_MASK;
	if (Mask) {
		SdiTx_CeAlignErrIntrHandler(SdiTxPtr);
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
	Mask = ActiveIntr & XV_SDITX_ISR_AXI4S_VID_LOCK_MASK;
	if (Mask) {
		SdiTx_Axi4sVidLockIntrHandler(SdiTxPtr);
		XV_SdiTx_InterruptClear(SdiTxPtr, Mask);
	}
}
void XV_SdiTx_IntrHandler ( void * InstancePtr ) { u32 ActiveIntr ; u32 Mask ; XV_SdiTx * SdiTxPtr = ( XV_SdiTx * ) InstancePtr ; Xil_AssertVoid ( SdiTxPtr != NULL ) ; Xil_AssertVoid ( SdiTxPtr -> IsReady == XIL_COMPONENT_IS_READY ) ; ActiveIntr = XV_SdiTx_GetIntrStatus ( SdiTxPtr ) ; Mask = ActiveIntr & XV_SDITX_ISR_GTTX_RSTDONE_MASK ; if ( Mask ) { if ( XV_SdiTx_ReadReg ( SdiTxPtr -> Config . BaseAddress , XV_SDITX_SB_TX_STS_TDATA_OFFSET ) & XV_SDITX_SB_TX_STS_TDATA_GT_TX_RESETDONE_MASK ) { SdiTx_GtTxRstDoneIntrHandler ( SdiTxPtr ) ; } XV_SdiTx_InterruptClear ( SdiTxPtr , Mask ) ; } Mask = ActiveIntr & XV_SDITX_ISR_OVERFLOW_MASK ; if ( Mask ) { SdiTx_OverFlowIntrHandler ( SdiTxPtr ) ; XV_SdiTx_InterruptClear ( SdiTxPtr , Mask ) ; } Mask = ActiveIntr & XV_SDITX_ISR_UNDERFLOW_MASK ; if ( Mask ) { SdiTx_UnderFlowIntrHandler ( SdiTxPtr ) ; XV_SdiTx_InterruptClear ( SdiTxPtr , Mask ) ; } Mask = ActiveIntr & XV_SDITX_ISR_TX_CE_ALIGN_ERR_MASK ; if ( Mask ) { SdiTx_CeAlignErrIntrHandler ( SdiTxPtr ) ; XV_SdiTx_InterruptClear ( SdiTxPtr , Mask ) ; } Mask = ActiveIntr & XV_SDITX_ISR_AXI4S_VID_LOCK_MASK ; if ( Mask ) { SdiTx_Axi4sVidLockIntrHandler ( SdiTxPtr ) ; XV_SdiTx_InterruptClear ( SdiTxPtr , Mask ) ; } }
This function is the interrupt handler for the SDI TX driver.
This function is the interrupt handler for the SDI TX driver .
/* Verify arguments */ /* Get Active interrupts */ /* Read ISR register  for Gtresetdone*/ /* Check for GTTX_RSTDONE IRQ flag set */ /* Jump to GT reset done interrupt handler */ /* Clear handled interrupt(s) */ /* Read ISR register  for OVERRFLOW*/ /* Check for OVERFLOW IRQ flag set */ /* Jump to OVERFLOW interrupt handler */ /* Clear handled interrupt(s) */ /* Read ISR register  for UNDERFLOW*/ /* Check for UNDERFLOW IRQ flag set */ /* Jump to UNDERFLOW interrupt handler */ /* Clear handled interrupt(s) */ /* Read ISR register  for CE_ALIGN_ERROR*/ /* Check for CE_ALIGN_ERROR IRQ flag set */ /* Jump to CE_ALIGN_ERROR interrupt handler */ /* Clear handled interrupt(s) */ /* Read ISR register  for Axi4S Video lock*/ /* Check for Axi4s Video lock IRQ flag set */ /* Jump to Axi4s video lock interrupt handler */ /* Clear handled interrupt(s) */