]> git.itanic.dy.fi Git - linux-stable/blobdiff - net/sched/sch_taprio.c
net/sched: taprio: make qdisc_leaf() see the per-netdev-queue pfifo child qdiscs
[linux-stable] / net / sched / sch_taprio.c
index 9bec73019f94bece9aa94ff4dbe77a0864568c0c..86675a79da1e4ac1ede8934c93e2021639018e52 100644 (file)
@@ -1951,12 +1951,14 @@ static int taprio_dump(struct Qdisc *sch, struct sk_buff *skb)
 
 static struct Qdisc *taprio_leaf(struct Qdisc *sch, unsigned long cl)
 {
-       struct netdev_queue *dev_queue = taprio_queue_get(sch, cl);
+       struct taprio_sched *q = qdisc_priv(sch);
+       struct net_device *dev = qdisc_dev(sch);
+       unsigned int ntx = cl - 1;
 
-       if (!dev_queue)
+       if (ntx >= dev->num_tx_queues)
                return NULL;
 
-       return dev_queue->qdisc_sleeping;
+       return q->qdiscs[ntx];
 }
 
 static unsigned long taprio_find(struct Qdisc *sch, u32 classid)