struct pcl818_private *devpriv = dev->private;
struct comedi_subdevice *s = dev->read_subdev;
- if (!dev->attached) {
- comedi_error(dev, "premature interrupt");
+ if (!dev->attached || !devpriv->ai_cmd_running ||
+ !devpriv->ai_mode) {
+ outb(0, dev->iobase + PCL818_CLRINT);
return IRQ_HANDLED;
}
break;
}
- outb(0, dev->iobase + PCL818_CLRINT); /* clear INT request */
-
- if (!devpriv->ai_cmd_running || !devpriv->ai_mode) {
- comedi_error(dev, "bad IRQ!");
- return IRQ_NONE;
- }
-
- comedi_error(dev, "IRQ from unknown source!");
- return IRQ_NONE;
+ outb(0, dev->iobase + PCL818_CLRINT);
+ return IRQ_HANDLED;
}
static void pcl818_ai_mode13dma_int(int mode, struct comedi_device *dev,