diff --git a/drivers/staging/comedi/drivers/pcl816.c b/drivers/staging/comedi/drivers/pcl816.c index f9a0dac79eca..1b1708a58b67 100644 --- a/drivers/staging/comedi/drivers/pcl816.c +++ b/drivers/staging/comedi/drivers/pcl816.c @@ -488,7 +488,9 @@ static int pcl816_ai_cmdtest(struct comedi_device *dev, if (!cmd->scan_begin_src || tmp != cmd->scan_begin_src) err++; - if (!(cmd->convert_src & (TRIG_EXT | TRIG_TIMER))) + tmp = cmd->convert_src; + cmd->convert_src &= TRIG_EXT | TRIG_TIMER; + if (!cmd->convert_src || tmp != cmd->convert_src) err++; tmp = cmd->scan_end_src;