staging: comedi: jr3_pci: tidy up jr3_pci_ai_insn_read()
Refactor this function to make it clearer.
The channel does not need to be validated. The comedi core does that for us.
Exit early if the subdevice private data is invalid.
Exit early if the subdevice 'state' is not done or there is an error.
Factor out the code that actually reads the channel data to reduce the
indent level.
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>