staging: comedi: refactor comedi_dev_from_minor()
authorIan Abbott <abbotti@mev.co.uk>
Thu, 4 Apr 2013 13:59:12 +0000 (14:59 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 5 Apr 2013 21:33:20 +0000 (14:33 -0700)
commitf3abc831386e3606fbb21acf0ee5231df0d0185f
tree483bb4cced3c62813fbbafb370c24ef95de3bdc9
parent5e04c25435e2cf0049def6ab4c28e49494a68dde
staging: comedi: refactor comedi_dev_from_minor()

Refactor `comedi_dev_from_minor()` to call one of two new functions
`comedi_dev_from_board_minor()` (for minor device numbers less than
`COMEDI_NUM_BOARD_MINORS`) or `comedi_dev_from_subdevice_minor()` (for
minor device numbers greater than or equal to `COMEDI_NUM_BOARD_MINORS`,
which are subdevice minor device numbers).

Remove `comedi_file_info_from_minor()` as it is no longer used.

This is a step towards removing `struct comedi_file_info`.

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