From e245b6d12691c1e178a6a075ac3cd1b7cd0d2e0e Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Mon, 22 Apr 2013 18:36:45 -0700 Subject: staging: comedi: das800: tidy up das800_di_insn_bits() For digital input subdevices, the (*insn_bits) function simply needs to return the status of the input channels in data[1]. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- drivers/staging/comedi/drivers/das800.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'drivers/staging') diff --git a/drivers/staging/comedi/drivers/das800.c b/drivers/staging/comedi/drivers/das800.c index 4f6698dc76d..cc4202eb395 100644 --- a/drivers/staging/comedi/drivers/das800.c +++ b/drivers/staging/comedi/drivers/das800.c @@ -632,12 +632,7 @@ static int das800_di_insn_bits(struct comedi_device *dev, struct comedi_insn *insn, unsigned int *data) { - unsigned int bits; - - bits = inb(dev->iobase + DAS800_STATUS) >> 4; - bits &= 0x7; - data[1] = bits; - data[0] = 0; + data[1] = (inb(dev->iobase + DAS800_STATUS) >> 4) & 0x7; return insn->n; } -- cgit v1.2.3-18-g5258