Skip to content

Commit

Permalink
staging: comedi: addi_apci_2032: cleanup the s->subdev_flags
Browse files Browse the repository at this point in the history
The flags SDF_GROUND and SDF_COMMON only have meaning for analog
input/output subdevices. Remove these flags from the digital
output and timer subdevices in this driver.

The digital output subdevice does not need the SDF_READABLE flag.
Remove 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>
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Nov 30, 2012
1 parent c0c3c7d commit 61034e0
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/staging/comedi/drivers/addi_apci_2032.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ static int apci2032_auto_attach(struct comedi_device *dev,
/* Initialize the digital output subdevice */
s = &dev->subdevices[0];
s->type = COMEDI_SUBD_DO;
s->subdev_flags =
SDF_READABLE | SDF_WRITEABLE | SDF_GROUND | SDF_COMMON;
s->subdev_flags = SDF_WRITEABLE;
s->n_chan = 32;
s->maxdata = 1;
s->range_table = &range_digital;
Expand All @@ -71,7 +70,7 @@ static int apci2032_auto_attach(struct comedi_device *dev,
/* Initialize the watchdog subdevice */
s = &dev->subdevices[1];
s->type = COMEDI_SUBD_TIMER;
s->subdev_flags = SDF_WRITEABLE | SDF_GROUND | SDF_COMMON;
s->subdev_flags = SDF_WRITEABLE;
s->n_chan = 1;
s->maxdata = 0;
s->len_chanlist = 1;
Expand Down

0 comments on commit 61034e0

Please sign in to comment.