提交 fb5a88eb 编写于 作者: I Ian Abbott 提交者: Greg Kroah-Hartman

staging: comedi: ni_mio_common: don't change CMDF_WRITE flag

There is no need for `ni_ai_cmdtest()` or `ni_ao_cmdtest()` to set the
`CMDF_WRITE` flag to the correct state as it has already been done by
the core comedi module.
Signed-off-by: NIan Abbott <abbotti@mev.co.uk>
Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 8986d37a
...@@ -2237,9 +2237,6 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s, ...@@ -2237,9 +2237,6 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
/* Step 1 : check if triggers are trivially valid */ /* Step 1 : check if triggers are trivially valid */
if ((cmd->flags & CMDF_WRITE))
cmd->flags &= ~CMDF_WRITE;
err |= cfc_check_trigger_src(&cmd->start_src, err |= cfc_check_trigger_src(&cmd->start_src,
TRIG_NOW | TRIG_INT | TRIG_EXT); TRIG_NOW | TRIG_INT | TRIG_EXT);
err |= cfc_check_trigger_src(&cmd->scan_begin_src, err |= cfc_check_trigger_src(&cmd->scan_begin_src,
...@@ -3272,9 +3269,6 @@ static int ni_ao_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s, ...@@ -3272,9 +3269,6 @@ static int ni_ao_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
/* Step 1 : check if triggers are trivially valid */ /* Step 1 : check if triggers are trivially valid */
if ((cmd->flags & CMDF_WRITE) == 0)
cmd->flags |= CMDF_WRITE;
err |= cfc_check_trigger_src(&cmd->start_src, TRIG_INT | TRIG_EXT); err |= cfc_check_trigger_src(&cmd->start_src, TRIG_INT | TRIG_EXT);
err |= cfc_check_trigger_src(&cmd->scan_begin_src, err |= cfc_check_trigger_src(&cmd->scan_begin_src,
TRIG_TIMER | TRIG_EXT); TRIG_TIMER | TRIG_EXT);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册