Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

net: Clean up explicit ->tx_queue references in link watch.

First, we add a qdisc_tx_changing() helper which returns true if the
qdisc attachment is in transition.

Second, we remove an assertion warning which is of limited value and
is hard to express precisely in a multiqueue environment.

Signed-off-by: David S. Miller <davem@davemloft.net>

+13 -10
+8
include/net/sch_generic.h
··· 242 242 return (q->q.qlen == 0); 243 243 } 244 244 245 + /* Are any of the TX qdiscs changing? */ 246 + static inline bool qdisc_tx_changing(struct net_device *dev) 247 + { 248 + struct netdev_queue *txq = &dev->tx_queue; 249 + 250 + return (txq->qdisc != txq->qdisc_sleeping); 251 + } 252 + 245 253 static inline int __qdisc_enqueue_tail(struct sk_buff *skb, struct Qdisc *sch, 246 254 struct sk_buff_head *list) 247 255 {