summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/sun
diff options
context:
space:
mode:
authorAllen Pais <allen.lkml@gmail.com>2017-09-21 20:04:26 +0300
committerDavid S. Miller <davem@davemloft.net>2017-09-21 21:44:39 +0300
commitba4cc08793a58a97cffc2769acaa53fff4433332 (patch)
tree49eac61599a24ad5cafdfe64d714bc438351400a /drivers/net/ethernet/sun
parent27dd0852644966c43079d3f812ec37e3e3fc864e (diff)
downloadlinux-ba4cc08793a58a97cffc2769acaa53fff4433332.tar.xz
drivers : net: niu: use setup_timer() helper.
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>
Diffstat (limited to 'drivers/net/ethernet/sun')
-rw-r--r--drivers/net/ethernet/sun/niu.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/ethernet/sun/niu.c b/drivers/net/ethernet/sun/niu.c
index 6a4e8e1bbd90..bde19b307d0d 100644
--- a/drivers/net/ethernet/sun/niu.c
+++ b/drivers/net/ethernet/sun/niu.c
@@ -6123,10 +6123,8 @@ static int niu_open(struct net_device *dev)
err = niu_init_hw(np);
if (!err) {
- init_timer(&np->timer);
+ setup_timer(&np->timer, niu_timer, (unsigned long)np);
np->timer.expires = jiffies + HZ;
- np->timer.data = (unsigned long) np;
- np->timer.function = niu_timer;
err = niu_enable_interrupts(np, 1);
if (err)