From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752060AbdIVI1b (ORCPT ); Fri, 22 Sep 2017 04:27:31 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:38196 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751970AbdIVI10 (ORCPT ); Fri, 22 Sep 2017 04:27:26 -0400 X-Google-Smtp-Source: AOwi7QC9ydxN748NtQw31fQOEJMHvKgtBbAyw7V0Ir2TOXwMVjzY69n3l25k5lymtAhQ1k9028YtSQ== From: Allen Pais To: linux-serial@vger.kernel.org Cc: linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org, jslaby@suse.com, Allen Pais Subject: [PATCH 08/10] drivers: tty: n_gsm: use setup_timer() helper. Date: Fri, 22 Sep 2017 13:56:50 +0530 Message-Id: <1506068812-8496-9-git-send-email-allen.lkml@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1506068812-8496-1-git-send-email-allen.lkml@gmail.com> References: <1506068812-8496-1-git-send-email-allen.lkml@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use setup_timer function instead of initializing timer with the function and data fields. Signed-off-by: Allen Pais --- drivers/tty/n_gsm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c index 0a3c966..33530d8 100644 --- a/drivers/tty/n_gsm.c +++ b/drivers/tty/n_gsm.c @@ -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; -- 2.7.4