提交 a72a8179 编写于 作者: S Stephen Hemminger 提交者: Jeff Garzik

b44: timer power saving

Make the PHY and statistic timer run on one second boundary
for powersaving.

On resume, the driver should check for link up immediately, to
get online faster (rather than waiting for the next second).
Signed-off-by: NStephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: NJeff Garzik <jeff@garzik.org>
上级 eb034a79
...@@ -599,8 +599,7 @@ static void b44_timer(unsigned long __opaque) ...@@ -599,8 +599,7 @@ static void b44_timer(unsigned long __opaque)
spin_unlock_irq(&bp->lock); spin_unlock_irq(&bp->lock);
bp->timer.expires = jiffies + HZ; mod_timer(&bp->timer, round_jiffies(jiffies + HZ));
add_timer(&bp->timer);
} }
static void b44_tx(struct b44 *bp) static void b44_tx(struct b44 *bp)
...@@ -2348,11 +2347,11 @@ static int b44_resume(struct pci_dev *pdev) ...@@ -2348,11 +2347,11 @@ static int b44_resume(struct pci_dev *pdev)
netif_device_attach(bp->dev); netif_device_attach(bp->dev);
spin_unlock_irq(&bp->lock); spin_unlock_irq(&bp->lock);
bp->timer.expires = jiffies + HZ;
add_timer(&bp->timer);
b44_enable_ints(bp); b44_enable_ints(bp);
netif_wake_queue(dev); netif_wake_queue(dev);
mod_timer(&bp->timer, jiffies + 1);
return 0; return 0;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册