Commit 05e1e76e authored by Manuel Schölling's avatar Manuel Schölling Committed by David S. Miller

micrel: Use time_before_eq()

To be future-proof and for better readability the time comparisons are modified
to use time_before_eq() instead of plain, error-prone math.
Signed-off-by: default avatarManuel Schölling <manuel.schoelling@gmx.de>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 87f03cc3
...@@ -4930,7 +4930,7 @@ static void netdev_tx_timeout(struct net_device *dev) ...@@ -4930,7 +4930,7 @@ static void netdev_tx_timeout(struct net_device *dev)
* Only reset the hardware if time between calls is long * Only reset the hardware if time between calls is long
* enough. * enough.
*/ */
if (jiffies - last_reset <= dev->watchdog_timeo) if (time_before_eq(jiffies, last_reset + dev->watchdog_timeo))
hw_priv = NULL; hw_priv = NULL;
} }
......
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