Commit 32db0345 authored by Allen Pais's avatar Allen Pais Committed by David S. Miller

drivers: net: smsc: use setup_timer() helper.

Use setup_timer function instead of initializing timer with the
    function and data fields.
Signed-off-by: default avatarAllen Pais <allen.lkml@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 0625d739
...@@ -739,10 +739,8 @@ static int epic_open(struct net_device *dev) ...@@ -739,10 +739,8 @@ static int epic_open(struct net_device *dev)
/* Set the timer to switch to check for link beat and perhaps switch /* Set the timer to switch to check for link beat and perhaps switch
to an alternate media type. */ to an alternate media type. */
init_timer(&ep->timer); setup_timer(&ep->timer, epic_timer, (unsigned long)dev);
ep->timer.expires = jiffies + 3*HZ; ep->timer.expires = jiffies + 3*HZ;
ep->timer.data = (unsigned long)dev;
ep->timer.function = epic_timer; /* timer handler */
add_timer(&ep->timer); add_timer(&ep->timer);
return rc; return rc;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment