diff options
author | H Hartley Sweeten <hartleys@visionengravers.com> | 2012-11-02 01:26:45 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-11-02 19:23:48 +0100 |
commit | f2c872e1983cfcc9e46e90bbdbb139d5c8698244 (patch) | |
tree | 5cd55b1863449ee1cbfe1d9a2ac747f59a898f0d | |
parent | staging: comedi: addi_apci_3120: remove test for DO subdevice (diff) | |
download | linux-f2c872e1983cfcc9e46e90bbdbb139d5c8698244.tar.xz linux-f2c872e1983cfcc9e46e90bbdbb139d5c8698244.zip |
staging: comedi: addi_apci_3120: remove test for DI subdevice
The boards supported by this driver all have digital inputs.
Remove the test for it.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/comedi/drivers/addi_apci_3120.c | 28 |
1 files changed, 13 insertions, 15 deletions
diff --git a/drivers/staging/comedi/drivers/addi_apci_3120.c b/drivers/staging/comedi/drivers/addi_apci_3120.c index 5f82f10ba585..3282c54f6116 100644 --- a/drivers/staging/comedi/drivers/addi_apci_3120.c +++ b/drivers/staging/comedi/drivers/addi_apci_3120.c @@ -240,23 +240,21 @@ static int apci3120_attach_pci(struct comedi_device *dev, } else { s->type = COMEDI_SUBD_UNUSED; } + /* Allocate and Initialise DI Subdevice Structures */ s = &dev->subdevices[2]; - if (this_board->i_NbrDiChannel) { - s->type = COMEDI_SUBD_DI; - s->subdev_flags = SDF_READABLE | SDF_GROUND | SDF_COMMON; - s->n_chan = this_board->i_NbrDiChannel; - s->maxdata = 1; - s->len_chanlist = this_board->i_NbrDiChannel; - s->range_table = &range_digital; - s->io_bits = 0; /* all bits input */ - s->insn_config = this_board->di_config; - s->insn_read = this_board->di_read; - s->insn_write = this_board->di_write; - s->insn_bits = this_board->di_bits; - } else { - s->type = COMEDI_SUBD_UNUSED; - } + s->type = COMEDI_SUBD_DI; + s->subdev_flags = SDF_READABLE | SDF_GROUND | SDF_COMMON; + s->n_chan = this_board->i_NbrDiChannel; + s->maxdata = 1; + s->len_chanlist = this_board->i_NbrDiChannel; + s->range_table = &range_digital; + s->io_bits = 0; /* all bits input */ + s->insn_config = this_board->di_config; + s->insn_read = this_board->di_read; + s->insn_write = this_board->di_write; + s->insn_bits = this_board->di_bits; + /* Allocate and Initialise DO Subdevice Structures */ s = &dev->subdevices[3]; s->type = COMEDI_SUBD_DO; |