staging: comedi: rti800: use arrays to hold the ai/ao ranges
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Tue, 9 Apr 2013 01:17:43 +0000 (18:17 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 9 Apr 2013 23:29:05 +0000 (16:29 -0700)
commit630a334b430fc4b4e13f9ddb5f7ddc42c45789d9
tree242b35f8f2fded6cf42a7409913db94344fa5dcb
parent7ae8de37fea41d3728d37c048760e1e205871882
staging: comedi: rti800: use arrays to hold the ai/ao ranges

The analog in/analog out ranges are selected by the user using options
passed during the legacy attach. Put the valid ranges into arrays and
use those instead of the switch () statements when initializing the
subdevice range information.

If the passed user option is not valid, set the range information to
range_unknown.

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