提交 a9aa5e33 编写于 作者: S Sebastian Andrzej Siewior 提交者: David S. Miller

net: dev: Change the order of the arguments for the contended condition.

Change the order of arguments and make qdisc_is_running() appear first.
This is more readable for the general case.
Signed-off-by: NSebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 d0c3e464
...@@ -3724,7 +3724,7 @@ static inline int __dev_xmit_skb(struct sk_buff *skb, struct Qdisc *q, ...@@ -3724,7 +3724,7 @@ static inline int __dev_xmit_skb(struct sk_buff *skb, struct Qdisc *q,
* sent after the qdisc owner is scheduled again. To prevent this * sent after the qdisc owner is scheduled again. To prevent this
* scenario the task always serialize on the lock. * scenario the task always serialize on the lock.
*/ */
contended = IS_ENABLED(CONFIG_PREEMPT_RT) || qdisc_is_running(q); contended = qdisc_is_running(q) || IS_ENABLED(CONFIG_PREEMPT_RT);
if (unlikely(contended)) if (unlikely(contended))
spin_lock(&q->busylock); spin_lock(&q->busylock);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册