From 31a4590ee31f2b46d28a4b85f84b04e90fa7ae00 Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Wed, 13 Jun 2012 17:58:07 -0700 Subject: [PATCH] staging: comedi: pcl812: remove unneeded tests in pcl812_ai_cmdtest The step 2 tests to make sure that the triggers are unique is not needed for single source triggers. These were already trivially validated in step 1. Signed-off-by: H Hartley Sweeten Cc: Ian Abbott Cc: Frank Mori Hess Signed-off-by: Greg Kroah-Hartman --- drivers/staging/comedi/drivers/pcl812.c | 27 ------------------------- 1 file changed, 27 deletions(-) diff --git a/drivers/staging/comedi/drivers/pcl812.c b/drivers/staging/comedi/drivers/pcl812.c index 0a4074af8a60..511c90136439 100644 --- a/drivers/staging/comedi/drivers/pcl812.c +++ b/drivers/staging/comedi/drivers/pcl812.c @@ -612,33 +612,6 @@ static int pcl812_ai_cmdtest(struct comedi_device *dev, * unique and mutually compatible */ - if (cmd->start_src != TRIG_NOW) { - cmd->start_src = TRIG_NOW; - err++; - } - - if (cmd->scan_begin_src != TRIG_FOLLOW) { - cmd->scan_begin_src = TRIG_FOLLOW; - err++; - } - - if (devpriv->use_ext_trg) { - if (cmd->convert_src != TRIG_EXT) { - cmd->convert_src = TRIG_EXT; - err++; - } - } else { - if (cmd->convert_src != TRIG_TIMER) { - cmd->convert_src = TRIG_TIMER; - err++; - } - } - - if (cmd->scan_end_src != TRIG_COUNT) { - cmd->scan_end_src = TRIG_COUNT; - err++; - } - if (cmd->stop_src != TRIG_NONE && cmd->stop_src != TRIG_COUNT) err++; -- 2.39.5