Input: locomokbd - use setup_timer

Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
This commit is contained in:
Geliang Tang 2017-04-10 20:38:10 -07:00 committed by Dmitry Torokhov
parent d8f2bed04c
commit cfecc1ebdc
1 changed files with 2 additions and 3 deletions

View File

@ -264,9 +264,8 @@ static int locomokbd_probe(struct locomo_dev *dev)
spin_lock_init(&locomokbd->lock);
init_timer(&locomokbd->timer);
locomokbd->timer.function = locomokbd_timer_callback;
locomokbd->timer.data = (unsigned long) locomokbd;
setup_timer(&locomokbd->timer, locomokbd_timer_callback,
(unsigned long)locomokbd);
locomokbd->suspend_jiffies = jiffies;