diff options
author | H Hartley Sweeten <hartleys@visionengravers.com> | 2012-11-05 14:40:02 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-11-06 09:30:57 +0100 |
commit | a3de4cd33c63c256b2521e61e487ae99cf313d94 (patch) | |
tree | 76d114a3c9cd56748caea82d504ad24ce1d671e4 /drivers/staging/comedi/drivers/addi_apci_1032.c | |
parent | b4c137506e85b2f2cfe41eb73aa7ece9f39ade40 (diff) | |
download | linux-rt-a3de4cd33c63c256b2521e61e487ae99cf313d94.tar.gz |
staging: comedi: addi_apci_1032: cleanup i_APCI1032_ReadMoreDigitalInput()
Move this function from hwdrv_apci1032.c.
Remove the unnecessary comment and rename the CamelCase function to
apci1032_di_insn_bits().
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/comedi/drivers/addi_apci_1032.c')
-rw-r--r-- | drivers/staging/comedi/drivers/addi_apci_1032.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/staging/comedi/drivers/addi_apci_1032.c b/drivers/staging/comedi/drivers/addi_apci_1032.c index 77e78df65b89..9e60d1f30e6d 100644 --- a/drivers/staging/comedi/drivers/addi_apci_1032.c +++ b/drivers/staging/comedi/drivers/addi_apci_1032.c @@ -12,6 +12,16 @@ static irqreturn_t v_ADDI_Interrupt(int irq, void *d) return IRQ_RETVAL(1); } +static int apci1032_di_insn_bits(struct comedi_device *dev, + struct comedi_subdevice *s, + struct comedi_insn *insn, + unsigned int *data) +{ + data[1] = inl(dev->iobase + APCI1032_DI_REG); + + return insn->n; +} + static int apci1032_reset(struct comedi_device *dev) { /* disable the interrupts */ @@ -74,7 +84,7 @@ static int apci1032_attach_pci(struct comedi_device *dev, s->len_chanlist = 32; s->range_table = &range_digital; s->insn_config = i_APCI1032_ConfigDigitalInput; - s->insn_bits = i_APCI1032_ReadMoreDigitalInput; + s->insn_bits = apci1032_di_insn_bits; /* Allocate and Initialise DO Subdevice Structures */ s = &dev->subdevices[3]; |