mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-12 16:15:05 -04:00
staging: comedi: addi_apci_3120: move timer 2 enable in apci3120_cyclic_ai()
Move the enable of timer 2 to avoid needing the extra if() check. 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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
5c66a77e1d
commit
b72b365666
@@ -462,12 +462,11 @@ static int apci3120_cyclic_ai(int mode,
|
||||
|
||||
devpriv->b_Timer2Mode = APCI3120_COUNTER;
|
||||
devpriv->b_Timer2Interrupt = 1;
|
||||
|
||||
apci3120_timer_enable(dev, 2, true);
|
||||
}
|
||||
}
|
||||
|
||||
if (!devpriv->us_UseDma && cmd->stop_src == TRIG_COUNT)
|
||||
apci3120_timer_enable(dev, 2, true);
|
||||
|
||||
switch (mode) {
|
||||
case 1:
|
||||
apci3120_timer_enable(dev, 0, true);
|
||||
|
||||
Reference in New Issue
Block a user