staging: comedi: quatech_daqp_cs: introduce daqp_ai_get_sample()
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Mon, 5 Oct 2015 21:22:50 +0000 (14:22 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 13 Oct 2015 04:16:05 +0000 (21:16 -0700)
commitc3f7e15383a9e86a56820c34d5ef761c4682e47b
tree3a5c9aabbaea57cd33edd3c20d815c15a4054697
parent4d6b700801bfeef15a059fc6739bfcd741cd9c15
staging: comedi: quatech_daqp_cs: introduce daqp_ai_get_sample()

Introduce a helper function to get a two's complement sample from
the FIFO and munge it to the offset binary format that comedi uses.

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/quatech_daqp_cs.c