Skip to content

Commit

Permalink
drivers: tty: n_gsm: use setup_timer() helper.
Browse files Browse the repository at this point in the history
        Use setup_timer function instead of initializing timer with the
        function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Allen Pais authored and Greg Kroah-Hartman committed Oct 3, 2017
1 parent 9b363c8 commit 65f8824
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/tty/n_gsm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1646,9 +1646,7 @@ static struct gsm_dlci *gsm_dlci_alloc(struct gsm_mux *gsm, int addr)
}

skb_queue_head_init(&dlci->skb_list);
init_timer(&dlci->t1);
dlci->t1.function = gsm_dlci_t1;
dlci->t1.data = (unsigned long)dlci;
setup_timer(&dlci->t1, gsm_dlci_t1, (unsigned long)dlci);
tty_port_init(&dlci->port);
dlci->port.ops = &gsm_port_ops;
dlci->gsm = gsm;
Expand Down

0 comments on commit 65f8824

Please sign in to comment.