Skip to contentSkip to conversation

ucb1400: Use disable_irq_nosync() from within irq handlers.

PATCH Applied Ben Nizette 1 participant 1 message Apr 16, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 6/9 ucb1400: Use disable_irq_nosync() from within irq handlers.

disable_irq() should wait for all running handlers to complete before returning. As such, if it's used to disable an interrupt from that interrupt's handler it will deadlock. This replaces the dangerous instances with the _nosync() variant which doesn't have this problem.

---

drivers/input/touchscreen/ucb1400_ts.c +1 -1
index e868264..f100c7f 100644
@@ -256,7 +256,7 @@ static irqreturn_t ucb1400_hard_irq(int irqnr, void *devid)
 	struct ucb1400_ts *ucb = devid;
 
 	if (irqnr == ucb->irq) {
-		disable_irq(ucb->irq);
+		disable_irq_nosync(ucb->irq);
 		ucb->irq_pending = 1;
 		wake_up(&ucb->ts_wait);
 		return IRQ_HANDLED;
Signature · 1 line
1.6.0.2