Commit 1c38d03e authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: hwdrv_apci3501: remove "magic" numbers in apci3501_read_insn_timer()

Use register bit defines from addi_tcw.h to remove the "magic" numbers.
Signed-off-by: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0d5e0307
......@@ -133,7 +133,8 @@ static int apci3501_read_insn_timer(struct comedi_device *dev,
devpriv->timer_mode != ADDIDATA_WATCHDOG)
return -EINVAL;
data[0] = inl(devpriv->tcw + ADDI_TCW_STATUS_REG) & 0x1;
data[0] = inl(devpriv->tcw + ADDI_TCW_STATUS_REG) &
ADDI_TCW_STATUS_OVERFLOW;
data[1] = inl(devpriv->tcw + ADDI_TCW_VAL_REG);
return insn->n;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment