aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/netdevice.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r--include/linux/netdevice.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 76cc099c8580..75f02d8c6ed3 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -924,10 +924,10 @@ static inline void netif_tx_lock_bh(struct net_device *dev)
924 924
925static inline int netif_tx_trylock(struct net_device *dev) 925static inline int netif_tx_trylock(struct net_device *dev)
926{ 926{
927 int err = spin_trylock(&dev->_xmit_lock); 927 int ok = spin_trylock(&dev->_xmit_lock);
928 if (!err) 928 if (likely(ok))
929 dev->xmit_lock_owner = smp_processor_id(); 929 dev->xmit_lock_owner = smp_processor_id();
930 return err; 930 return ok;
931} 931}
932 932
933static inline void netif_tx_unlock(struct net_device *dev) 933static inline void netif_tx_unlock(struct net_device *dev)