mirror of
https://github.com/torvalds/linux.git
synced 2026-05-21 13:27:57 +02:00
net: ethernet: use time_is_before_eq_jiffies() instead of open coding it
Use the helper function time_is_{before,after}_jiffies() to improve
code readability.
Signed-off-by: Wang Qing <wangqing@vivo.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
a5081bad2e
commit
882edc0621
|
|
@ -28,6 +28,7 @@
|
|||
#include <linux/udp.h>
|
||||
#include <linux/if_vlan.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/jiffies.h>
|
||||
#include <net/ip6_checksum.h>
|
||||
#include "jme.h"
|
||||
|
||||
|
|
@ -2179,7 +2180,7 @@ jme_stop_queue_if_full(struct jme_adapter *jme)
|
|||
}
|
||||
|
||||
if (unlikely(txbi->start_xmit &&
|
||||
(jiffies - txbi->start_xmit) >= TX_TIMEOUT &&
|
||||
time_is_before_eq_jiffies(txbi->start_xmit + TX_TIMEOUT) &&
|
||||
txbi->skb)) {
|
||||
netif_stop_queue(jme->dev);
|
||||
netif_info(jme, tx_queued, jme->dev,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user