浏览代码

[NET]: Make net watchdog timers 1 sec jiffy aligned.

round_jiffies for net dev watchdog timer.

Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Venkatesh Pallipadi 18 年之前
父节点
当前提交
60468d5b5b
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      net/sched/sch_generic.c

+ 2 - 1
net/sched/sch_generic.c

@@ -224,7 +224,8 @@ void __netdev_watchdog_up(struct net_device *dev)
 	if (dev->tx_timeout) {
 	if (dev->tx_timeout) {
 		if (dev->watchdog_timeo <= 0)
 		if (dev->watchdog_timeo <= 0)
 			dev->watchdog_timeo = 5*HZ;
 			dev->watchdog_timeo = 5*HZ;
-		if (!mod_timer(&dev->watchdog_timer, jiffies + dev->watchdog_timeo))
+		if (!mod_timer(&dev->watchdog_timer,
+			       round_jiffies(jiffies + dev->watchdog_timeo)))
 			dev_hold(dev);
 			dev_hold(dev);
 	}
 	}
 }
 }