summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH Hartley Sweeten <hsweeten@visionengravers.com>2015-01-07 17:19:26 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-01-09 17:03:54 -0800
commit3b78602f7dfdb187c62923213f19c7e39f300d70 (patch)
tree7538db02cfd4c064034a70f148d5996fc94a890a
parentb1ad96846bc08ded159dfd9700727c225abb9c04 (diff)
staging: comedi: aio_iiro_16: fix subdevice 0 'type'
Subdevice 0 is a digial output not a digital I/O subdevice. Fix the type and, for aesthetics, rename the (*insn_bits) function used to set the outputs. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/comedi/drivers/aio_iiro_16.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/staging/comedi/drivers/aio_iiro_16.c b/drivers/staging/comedi/drivers/aio_iiro_16.c
index 7b5ed439c164..87d1372f7aab 100644
--- a/drivers/staging/comedi/drivers/aio_iiro_16.c
+++ b/drivers/staging/comedi/drivers/aio_iiro_16.c
@@ -39,10 +39,10 @@ Configuration Options:
#define AIO_IIRO_16_RELAY_8_15 0x04
#define AIO_IIRO_16_INPUT_8_15 0x05
-static int aio_iiro_16_dio_insn_bits_write(struct comedi_device *dev,
- struct comedi_subdevice *s,
- struct comedi_insn *insn,
- unsigned int *data)
+static int aio_iiro_16_do_insn_bits(struct comedi_device *dev,
+ struct comedi_subdevice *s,
+ struct comedi_insn *insn,
+ unsigned int *data)
{
if (comedi_dio_update_state(s, data)) {
outb(s->state & 0xff, dev->iobase + AIO_IIRO_16_RELAY_0_7);
@@ -82,12 +82,12 @@ static int aio_iiro_16_attach(struct comedi_device *dev,
return ret;
s = &dev->subdevices[0];
- s->type = COMEDI_SUBD_DIO;
+ s->type = COMEDI_SUBD_DO;
s->subdev_flags = SDF_WRITABLE;
s->n_chan = 16;
s->maxdata = 1;
s->range_table = &range_digital;
- s->insn_bits = aio_iiro_16_dio_insn_bits_write;
+ s->insn_bits = aio_iiro_16_do_insn_bits;
s = &dev->subdevices[1];
s->type = COMEDI_SUBD_DIO;