diff options
author | H Hartley Sweeten | 2015-10-12 21:16:33 +0200 |
---|---|---|
committer | Greg Kroah-Hartman | 2015-10-13 19:26:06 +0200 |
commit | c5fcb7cabc52dfc38ff4b31abc7aac11b54f6bd7 (patch) | |
tree | 09547c02676f2e1286ce07757c1db9cd3579784d /drivers/staging/comedi | |
parent | staging: comedi: aio_aio12_8: hookup 8254 counter/timer (diff) | |
download | kernel-qcow2-linux-c5fcb7cabc52dfc38ff4b31abc7aac11b54f6bd7.tar.gz kernel-qcow2-linux-c5fcb7cabc52dfc38ff4b31abc7aac11b54f6bd7.tar.xz kernel-qcow2-linux-c5fcb7cabc52dfc38ff4b31abc7aac11b54f6bd7.zip |
staging: comedi: aio_aio12_8: move comedi_lrange definition
For aesthetics, move the comedi_lrange definition used in this driver
to the follow the norm in comedi drivers and rename the variable.
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>
Diffstat (limited to 'drivers/staging/comedi')
-rw-r--r-- | drivers/staging/comedi/drivers/aio_aio12_8.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/staging/comedi/drivers/aio_aio12_8.c b/drivers/staging/comedi/drivers/aio_aio12_8.c index 0ba557ef9a7f..f9a90e5259c6 100644 --- a/drivers/staging/comedi/drivers/aio_aio12_8.c +++ b/drivers/staging/comedi/drivers/aio_aio12_8.c @@ -76,6 +76,15 @@ #define AIO12_8_DAC_ENABLE_REG 0x18 #define AIO12_8_DAC_ENABLE_REF_ENA BIT(0) +static const struct comedi_lrange aio_aio12_8_range = { + 4, { + UNI_RANGE(5), + BIP_RANGE(5), + UNI_RANGE(10), + BIP_RANGE(10) + } +}; + struct aio12_8_boardtype { const char *name; int ai_nchan; @@ -188,15 +197,6 @@ static int aio_aio12_8_counter_insn_config(struct comedi_device *dev, return insn->n; } -static const struct comedi_lrange range_aio_aio12_8 = { - 4, { - UNI_RANGE(5), - BIP_RANGE(5), - UNI_RANGE(10), - BIP_RANGE(10) - } -}; - static int aio_aio12_8_attach(struct comedi_device *dev, struct comedi_devconfig *it) { @@ -224,7 +224,7 @@ static int aio_aio12_8_attach(struct comedi_device *dev, s->subdev_flags = SDF_READABLE | SDF_GROUND | SDF_DIFF; s->n_chan = board->ai_nchan; s->maxdata = 0x0fff; - s->range_table = &range_aio_aio12_8; + s->range_table = &aio_aio12_8_range; s->insn_read = aio_aio12_8_ai_read; } else { s->type = COMEDI_SUBD_UNUSED; @@ -237,7 +237,7 @@ static int aio_aio12_8_attach(struct comedi_device *dev, s->subdev_flags = SDF_WRITABLE | SDF_GROUND | SDF_DIFF; s->n_chan = 4; s->maxdata = 0x0fff; - s->range_table = &range_aio_aio12_8; + s->range_table = &aio_aio12_8_range; s->insn_write = aio_aio12_8_ao_insn_write; ret = comedi_alloc_subdev_readback(s); |