]> git.baikalelectronics.ru Git - kernel.git/commit
staging: comedi: dt282x: fix bug where DIO direction is reset to inputs
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Fri, 20 Jun 2014 20:13:01 +0000 (13:13 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Jun 2014 00:08:20 +0000 (20:08 -0400)
commitde99a61c38e06d684d265195cf010b3d916db563
treeec185f44191adb1564f441bbbf53c6b4485ce0b8
parentcb308123a0e00e8bf568f5fc73da5b47034dfc70
staging: comedi: dt282x: fix bug where DIO direction is reset to inputs

The direction of the 16 DIO channels is controlled with two bits in the
DACSR register. The HBOE bit controls the direction of channels 15-8 and
the LBOE bit channels 7-0.

The DACSR register is also used to control the Analog Output async command
support. Currently, starting or canceling an Analog Output command would
also reset the DIO directions so that all channels were inputs.

Fix the driver so that the DIO direction is not changed when starting or
canceling an Analog Output async command.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/dt282x.c