From: H Hartley Sweeten Date: Mon, 5 Oct 2015 21:23:07 +0000 (-0700) Subject: staging: comedi: quatech_daqp_cs: handle shared interrupt X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=77e7c200f37536e05f714bcebc34f58aba9eabfc;p=deliverable%2Flinux.git staging: comedi: quatech_daqp_cs: handle shared interrupt This is a PCMCIA driver and interrupts are always shared. Detect if the hardware did not produce the interrupt and return IRQ_NONE so that other drivers might handle it. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/comedi/drivers/quatech_daqp_cs.c b/drivers/staging/comedi/drivers/quatech_daqp_cs.c index 7432e5761539..c44e7ec19e47 100644 --- a/drivers/staging/comedi/drivers/quatech_daqp_cs.c +++ b/drivers/staging/comedi/drivers/quatech_daqp_cs.c @@ -214,6 +214,9 @@ static irqreturn_t daqp_interrupt(int irq, void *dev_id) return IRQ_NONE; status = inb(dev->iobase + DAQP_STATUS_REG); + if (!(status & DAQP_STATUS_EVENTS)) + return IRQ_NONE; + while (!(status & DAQP_STATUS_FIFO_EMPTY)) { unsigned short data;