]> www.infradead.org Git - users/jedix/linux-maple.git/commit
staging: comedi: cb_pcimdas: fix handlers for DI and DO subdevices
authorIan Abbott <abbotti@mev.co.uk>
Fri, 12 Jun 2015 15:37:41 +0000 (16:37 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 3 Aug 2015 16:28:59 +0000 (09:28 -0700)
commit366031c6dd1c6b57a9d48a66cdc48e21c994a1bd
tree038a1e6412ba5fd64e9489d3e4b922fdfb2f7aca
parent92c09183c74a03d85f2184992c9b0e3308c8bb8d
staging: comedi: cb_pcimdas: fix handlers for DI and DO subdevices

commit b08ad6657aacf9b5d7c4b22de2ba891b152d0528 upstream.

Normally, low-level Comedi drivers set an `insn_bits` handler for
digital input (DI), digital output (DO) and digital input/output (DIO)
subdevice types to handle normal reading and writing of digital
channels.  The "cb_pcimdas" driver currently has an `insn_read` handler
for the DI subdevice and an `insn_write` handler for the DO subdevice.
However, the actual handler functions `cb_pcimdas_di_insn_read()` and
`cb_pcimdas_do_insn_write()` are written to behave like `insn_bits`
handlers.  Something's wrong there!  To fix it, set the functions as
`insn_bits` handlers and rename them for consistency.

Fixes: e56d03dee14a ("staging: comedi: cb_pcimdas: add main connector digital input/output")
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/cb_pcimdas.c