fix for shared interrupt bug from steve.sharples@nottingham.ac.uk
authorFrank Mori Hess <fmhess@speakeasy.net>
Wed, 29 Sep 2004 12:28:26 +0000 (12:28 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Wed, 29 Sep 2004 12:28:26 +0000 (12:28 +0000)
comedi/drivers/amplc_pci230.c

index 987118aec02fa91e440070b18121102d5fbf3114..b9bb9ec9c812a0e7e30583ccf0780957e63e1883 100644 (file)
@@ -1133,6 +1133,10 @@ static irqreturn_t pci230_interrupt(int irq, void *d, struct pt_regs *regs)
        /* Read interrupt status/enable register. */
        status_int = inb(devpriv->pci_iobase + PCI230_INT_SCE);
 
+       if (status_int == PCI230_INT_DISABLE) {
+               return IRQ_NONE;
+       }
+
        /* Disable all of board's interrupts.
         * (Only those interrrupts that need re-enabling, are, later in the handler).  */
        devpriv->ier = PCI230_INT_DISABLE; 
@@ -1144,9 +1148,6 @@ static irqreturn_t pci230_interrupt(int irq, void *d, struct pt_regs *regs)
         * However, at present (Comedi-0.7.60) does not allow concurrent
         * execution of commands, instructions or a mixture of the two.
         */
-       if (status_int == PCI230_INT_DISABLE) {
-               return IRQ_NONE;
-       }
        
        if (status_int & PCI230_INT_ZCLK_CT1) {
                s = dev->write_subdev;