]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drivers: net: appletalk: use setup_timer() helper.
authorAllen Pais <allen.lkml@gmail.com>
Thu, 21 Sep 2017 17:05:13 +0000 (22:35 +0530)
committerDavid S. Miller <davem@davemloft.net>
Thu, 21 Sep 2017 18:44:43 +0000 (11:44 -0700)
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: David S. Miller <davem@davemloft.net>
drivers/net/appletalk/ltpc.c

index ac755d2950a63e2b2421217bb3b164d496d831c5..e4aa374caa4d5b7a65187e5c7b4f9743ba147b4b 100644 (file)
@@ -1165,9 +1165,7 @@ struct net_device * __init ltpc_probe(void)
                dev->irq = 0;
                /* polled mode -- 20 times per second */
                /* this is really, really slow... should it poll more often? */
-               init_timer(&ltpc_timer);
-               ltpc_timer.function=ltpc_poll;
-               ltpc_timer.data = (unsigned long) dev;
+               setup_timer(&ltpc_timer, ltpc_poll, (unsigned long)dev);
 
                ltpc_timer.expires = jiffies + HZ/20;
                add_timer(&ltpc_timer);