We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent efc8e72 commit 8eb0e45Copy full SHA for 8eb0e45
net/sched/sch_hfsc.c
@@ -1649,10 +1649,16 @@ hfsc_dequeue(struct Qdisc *sch)
1649
if (cl->qdisc->q.qlen != 0) {
1650
/* update ed */
1651
next_len = qdisc_peek_len(cl->qdisc);
1652
- if (realtime)
1653
- update_ed(cl, next_len);
1654
- else
1655
- update_d(cl, next_len);
+ /* Check queue length again since some qdisc implementations
+ * (e.g., netem/codel) might empty the queue during the peek
+ * operation.
+ */
1656
+ if (cl->qdisc->q.qlen != 0) {
1657
+ if (realtime)
1658
+ update_ed(cl, next_len);
1659
+ else
1660
+ update_d(cl, next_len);
1661
+ }
1662
} else {
1663
/* the class becomes passive */
1664
eltree_remove(cl);
0 commit comments