Skip to content

Commit

Permalink
pkt_sched: Never schedule non-root qdiscs.
Browse files Browse the repository at this point in the history
Based upon initial discovery and patch by Jarek Poplawski.

The qdisc watchdogs can be attached to any qdisc, not just the root,
so make sure we schedule the correct one.

CBQ has a similar bug.

Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed Aug 19, 2008
1 parent 6974765 commit 8608db0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion net/sched/sch_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ static enum hrtimer_restart qdisc_watchdog(struct hrtimer *timer)

wd->qdisc->flags &= ~TCQ_F_THROTTLED;
smp_wmb();
__netif_schedule(wd->qdisc);
__netif_schedule(qdisc_root(wd->qdisc));

return HRTIMER_NORESTART;
}
Expand Down
2 changes: 1 addition & 1 deletion net/sched/sch_cbq.c
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,7 @@ static enum hrtimer_restart cbq_undelay(struct hrtimer *timer)
}

sch->flags &= ~TCQ_F_THROTTLED;
__netif_schedule(sch);
__netif_schedule(qdisc_root(sch));
return HRTIMER_NORESTART;
}

Expand Down

0 comments on commit 8608db0

Please sign in to comment.