staging: comedi: das800: 'dev->subdevices + 0' is already known
authorH Hartley Sweeten <hartleys@visionengravers.com>
Thu, 6 Sep 2012 01:38:11 +0000 (18:38 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 6 Sep 2012 03:03:55 +0000 (20:03 -0700)
There is no need to calculate the subdevice for the call to
das800_cancel. The variable 's' in this function is set to the
'dev->read_subdev' which is the same as 'dev->subdevices + 0'.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/das800.c

index a0959a5e8747861bf0ed0c86eb1f5630101b2d1a..834054d7f10938e9f40d1e12b68a23d1396ffb58 100644 (file)
@@ -435,7 +435,7 @@ static irqreturn_t das800_interrupt(int irq, void *d)
        if (fifo_overflow) {
                spin_unlock_irqrestore(&dev->spinlock, irq_flags);
                comedi_error(dev, "DAS800 FIFO overflow");
-               das800_cancel(dev, dev->subdevices + 0);
+               das800_cancel(dev, s);
                async->events |= COMEDI_CB_ERROR | COMEDI_CB_EOA;
                comedi_event(dev, s);
                async->events = 0;