From 6b2f2b94b52a201797ab584f8ef8f2950bc3a122 Mon Sep 17 00:00:00 2001 From: Andrei-Liviu Simion Date: Thu, 12 Feb 2015 17:08:28 -0700 Subject: [PATCH] dp: tx: Removed interrupt masking from the interrupt handler. No need for this since the handler will never be called if the interrupts are masked in the first place. Also, by default, nested interrupts are disabled and it is up to the user to explicitly request nested interrupts - allow this. The interrupt mask should already apply in hardware. Signed-off-by: Andrei-Liviu Simion --- .../drivers/dp/src/xdp_intr.c | 20 ------------------- 1 file changed, 20 deletions(-) diff --git a/XilinxProcessorIPLib/drivers/dp/src/xdp_intr.c b/XilinxProcessorIPLib/drivers/dp/src/xdp_intr.c index c3e2db16..8ec4434e 100644 --- a/XilinxProcessorIPLib/drivers/dp/src/xdp_intr.c +++ b/XilinxProcessorIPLib/drivers/dp/src/xdp_intr.c @@ -613,37 +613,21 @@ static void XDp_TxInterruptHandler(XDp *InstancePtr) u8 HpdEventDetected; u8 HpdPulseDetected; u32 HpdDuration; - u32 IntrMask; /* Determine what kind of interrupt occurred. * Note: XDP_TX_INTERRUPT_STATUS is an RC (read-clear) register. */ IntrStatus = XDp_ReadReg(InstancePtr->Config.BaseAddr, XDP_TX_INTERRUPT_STATUS); - IntrStatus &= ~XDp_ReadReg(InstancePtr->Config.BaseAddr, - XDP_TX_INTERRUPT_MASK); - IntrMask = XDp_ReadReg(InstancePtr->Config.BaseAddr, - XDP_TX_INTERRUPT_MASK); HpdEventDetected = IntrStatus & XDP_TX_INTERRUPT_STATUS_HPD_EVENT_MASK; HpdPulseDetected = IntrStatus & XDP_TX_INTERRUPT_STATUS_HPD_PULSE_DETECTED_MASK; if (HpdEventDetected) { - /* Mask interrupts while event handling is taking place. API - * will error out in case of a disconnection event anyway. */ - XDp_WriteReg(InstancePtr->Config.BaseAddr, - XDP_TX_INTERRUPT_MASK, IntrMask | - XDP_TX_INTERRUPT_MASK_HPD_EVENT_MASK); - InstancePtr->TxInstance.HpdEventHandler( InstancePtr->TxInstance.HpdEventCallbackRef); } else if (HpdPulseDetected && XDp_TxIsConnected(InstancePtr)) { - /* Mask interrupts while event handling is taking place. */ - XDp_WriteReg(InstancePtr->Config.BaseAddr, - XDP_TX_INTERRUPT_MASK, IntrMask | - XDP_TX_INTERRUPT_MASK_HPD_PULSE_DETECTED_MASK); - /* The source device must debounce the incoming HPD signal by * sampling the value at an interval greater than 0.500 ms. An * HPD pulse should be of width 0.5 ms - 1.0 ms. */ @@ -654,10 +638,6 @@ static void XDp_TxInterruptHandler(XDp *InstancePtr) InstancePtr->TxInstance.HpdPulseCallbackRef); } } - - /* Unmask previously masked interrupts once handling is done. */ - XDp_WriteReg(InstancePtr->Config.BaseAddr, XDP_TX_INTERRUPT_MASK, - IntrMask); } /******************************************************************************/