staging: comedi: dt9812: convert digital out subdevice to (*insn_bits)
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Tue, 14 May 2013 21:32:42 +0000 (14:32 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 16 May 2013 23:26:02 +0000 (16:26 -0700)
commit36c973d0896a5319cf3089c20e8d9881bc60297e
treeeb1b12d147510d6d685880c91a696635e2a989be
parente81eaba6c425a5d06623e5ad93cb7b3c096e8d5c
staging: comedi: dt9812: convert digital out subdevice to (*insn_bits)

Currently the (*insn_write) function for the digital output subdevice
only sets the state for a single channel. It's more efficent to use
the (*insn_bits) function and allow setting the state for all the
channels.

The comedi core can use the (*insn_bits) to emulate the (*insn_write)
if needed.

Also, use the subdevice 'state' variable to hold the current state
of the channels instead of 'do_shadow' in the private data.

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>
drivers/staging/comedi/drivers/dt9812.c