From bea70d0b2dc078c7eab3049c44aade037ffbcb90 Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Thu, 5 Dec 2013 13:43:46 -0700 Subject: [PATCH] staging: comedi: ni_atmio16d: use dev->read_subdev Use the dev->read_subdev that was setup in the device attach instead of accessing the dev->subdevices array directly. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- drivers/staging/comedi/drivers/ni_atmio16d.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/comedi/drivers/ni_atmio16d.c b/drivers/staging/comedi/drivers/ni_atmio16d.c index 834c9e1e6058..3a92fe52b9ac 100644 --- a/drivers/staging/comedi/drivers/ni_atmio16d.c +++ b/drivers/staging/comedi/drivers/ni_atmio16d.c @@ -229,7 +229,7 @@ static void reset_atmio16d(struct comedi_device *dev) static irqreturn_t atmio16d_interrupt(int irq, void *d) { struct comedi_device *dev = d; - struct comedi_subdevice *s = &dev->subdevices[0]; + struct comedi_subdevice *s = dev->read_subdev; comedi_buf_put(s->async, inw(dev->iobase + AD_FIFO_REG)); -- 2.20.1