From: Allen Pais Date: Mon, 25 Sep 2017 07:30:03 +0000 (+0530) Subject: net: nfc: hci: use setup_timer() helper. X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=b1e07c5486f0df26caf93234bd7db5545a37aba8;p=linux.git net: nfc: hci: use setup_timer() helper. Use setup_timer function instead of initializing timer with the function and data fields. Signed-off-by: Allen Pais Signed-off-by: David S. Miller --- diff --git a/net/nfc/hci/core.c b/net/nfc/hci/core.c index b740fef0acc5e..a8a6e7814e091 100644 --- a/net/nfc/hci/core.c +++ b/net/nfc/hci/core.c @@ -1004,9 +1004,8 @@ int nfc_hci_register_device(struct nfc_hci_dev *hdev) INIT_WORK(&hdev->msg_tx_work, nfc_hci_msg_tx_work); - init_timer(&hdev->cmd_timer); - hdev->cmd_timer.data = (unsigned long)hdev; - hdev->cmd_timer.function = nfc_hci_cmd_timeout; + setup_timer(&hdev->cmd_timer, nfc_hci_cmd_timeout, + (unsigned long)hdev); skb_queue_head_init(&hdev->rx_hcp_frags);