diff options
author | H Hartley Sweeten <hartleys@visionengravers.com> | 2012-09-05 18:51:38 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-09-05 20:06:29 -0700 |
commit | 7d780555c03e052756b97ff6625dceb03e8575d8 (patch) | |
tree | 7554ac3798b5ff5c5075beb3f5834e6407b24479 | |
parent | d533ef070d0af7816616499fc4bf0eb36dfd63a6 (diff) | |
download | talos-op-linux-7d780555c03e052756b97ff6625dceb03e8575d8.tar.gz talos-op-linux-7d780555c03e052756b97ff6625dceb03e8575d8.zip |
staging: comedi: pcl725: remove subdevice pointer math
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>
-rw-r--r-- | drivers/staging/comedi/drivers/pcl725.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/comedi/drivers/pcl725.c b/drivers/staging/comedi/drivers/pcl725.c index d5b60cf7c93f..21fbc1ae1e73 100644 --- a/drivers/staging/comedi/drivers/pcl725.c +++ b/drivers/staging/comedi/drivers/pcl725.c @@ -62,7 +62,7 @@ static int pcl725_attach(struct comedi_device *dev, struct comedi_devconfig *it) if (ret) return ret; - s = dev->subdevices + 0; + s = &dev->subdevices[0]; /* do */ s->type = COMEDI_SUBD_DO; s->subdev_flags = SDF_WRITABLE; @@ -71,7 +71,7 @@ static int pcl725_attach(struct comedi_device *dev, struct comedi_devconfig *it) s->insn_bits = pcl725_do_insn; s->range_table = &range_digital; - s = dev->subdevices + 1; + s = &dev->subdevices[1]; /* di */ s->type = COMEDI_SUBD_DI; s->subdev_flags = SDF_READABLE; |