Skip to content

Commit

Permalink
Input: ff-memless - start playing FF effects immediately
Browse files Browse the repository at this point in the history
Instead of waiting for the next timer tick to start playing an effect
do it immediately. This mostly helps systems using low HZ setting.

Signed-off-by: Jari Vanhala <ext-jari.vanhala@nokia.com>
Acked-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
  • Loading branch information
Jari Vanhala authored and Dmitry Torokhov committed Dec 25, 2009
1 parent ea486e6 commit 25ae083
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions drivers/input/ff-memless.c
Original file line number Diff line number Diff line change
Expand Up @@ -411,19 +411,17 @@ static int ml_ff_playback(struct input_dev *dev, int effect_id, int value)
msecs_to_jiffies(state->effect->replay.length);
state->adj_at = state->play_at;

ml_schedule_timer(ml);

} else {
debug("initiated stop");

if (test_bit(FF_EFFECT_PLAYING, &state->flags))
__set_bit(FF_EFFECT_ABORTING, &state->flags);
else
__clear_bit(FF_EFFECT_STARTED, &state->flags);

ml_play_effects(ml);
}

ml_play_effects(ml);

return 0;
}

Expand Down

0 comments on commit 25ae083

Please sign in to comment.