Convert the comedi_subdevice access from pointer math to array
access.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
return ret;
for (i = 0; i < board->n_8255; i++) {
- s = dev->subdevices + i;
+ s = &dev->subdevices[i];
ret = subdev_8255_init(dev, s, NULL, dev->iobase + i * 4);
if (ret)
return ret;
if (dev->subdevices) {
for (i = 0; i < board->n_8255; i++) {
- s = dev->subdevices + i;
+ s = &dev->subdevices[i];
subdev_8255_cleanup(dev, s);
}
}