Skip to content

Commit

Permalink
Input: turbografx - use setup_timer
Browse files Browse the repository at this point in the history
Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
  • Loading branch information
geliangtang authored and dtor committed Apr 11, 2017
1 parent cfecc1e commit bee8449
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/input/joystick/turbografx.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,7 @@ static void tgfx_attach(struct parport *pp)
mutex_init(&tgfx->sem);
tgfx->pd = pd;
tgfx->parportno = pp->number;
init_timer(&tgfx->timer);
tgfx->timer.data = (long) tgfx;
tgfx->timer.function = tgfx_timer;
setup_timer(&tgfx->timer, tgfx_timer, (long)tgfx);

for (i = 0; i < n_devs; i++) {
if (n_buttons[i] < 1)
Expand Down

0 comments on commit bee8449

Please sign in to comment.