staging: comedi: ni_mio_common: convert NI_GPCT_SUBDEV to a macro
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Thu, 14 Apr 2016 16:57:59 +0000 (09:57 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 29 Apr 2016 05:17:28 +0000 (22:17 -0700)
commit0b235d5ce4e084535e27e0416449d3c3b0d133ea
tree21503805e40b0409ab82c325006b182c0033646e
parent73894987d6747f39fe7a08b5b25d33a2883d09e2
staging: comedi: ni_mio_common: convert NI_GPCT_SUBDEV to a macro

The 'counter_index' is always in range (0 to < NUM_GPCT, which is 2).

For aesthetics, convert this inline function into a macro and remove
the BUG() which can never occur.

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