提交 ac803d1c 编写于 作者: A Allen Pais 提交者: David S. Miller

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

Use setup_timer function instead of initializing timer with the
    function and data fields.
Signed-off-by: NAllen Pais <allen.lkml@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 6d2bcc14
......@@ -1065,10 +1065,8 @@ sis900_open(struct net_device *net_dev)
/* Set the timer to switch to check for link beat and perhaps switch
to an alternate media type. */
init_timer(&sis_priv->timer);
setup_timer(&sis_priv->timer, sis900_timer, (unsigned long)net_dev);
sis_priv->timer.expires = jiffies + HZ;
sis_priv->timer.data = (unsigned long)net_dev;
sis_priv->timer.function = sis900_timer;
add_timer(&sis_priv->timer);
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册