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

drivers: net: cisco_hdlc: 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 f347bd6b
...@@ -293,10 +293,8 @@ static void cisco_start(struct net_device *dev) ...@@ -293,10 +293,8 @@ static void cisco_start(struct net_device *dev)
st->up = st->txseq = st->rxseq = 0; st->up = st->txseq = st->rxseq = 0;
spin_unlock_irqrestore(&st->lock, flags); spin_unlock_irqrestore(&st->lock, flags);
init_timer(&st->timer); setup_timer(&st->timer, cisco_timer, (unsigned long)dev);
st->timer.expires = jiffies + HZ; /* First poll after 1 s */ st->timer.expires = jiffies + HZ; /* First poll after 1 s */
st->timer.function = cisco_timer;
st->timer.data = (unsigned long)dev;
add_timer(&st->timer); add_timer(&st->timer);
} }
......
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