staging: comedi: ni_labpc: clarify the cmd->start_arg validation
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Thu, 17 Apr 2014 17:08:04 +0000 (10:08 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 22 Apr 2014 17:21:32 +0000 (10:21 -0700)
commitc55881686302a5e7f19b82f0a163beec2cc314c3
tree7f465f78c5e1e195cd26b4fa04cc83d9887502f6
parent6a760394d7eb70a810bf472289473f915eb6da0d
staging: comedi: ni_labpc: clarify the cmd->start_arg validation

This driver supports cmd->start_src sources of TRIG_NOW and TRIG_EXT.
Refactor the (*do_cmdtest) to clarify the trivial validation of the
cmd->start_arg.

This also fixes a bug, the cmd->start_src has the trigger not the
cmd->start_arg.

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_labpc.c