net: sched: introduce and use qdisc tree flush/purge helpers
The same code to flush qdisc tree and purge the qdisc queue is duplicated in many places and in most cases it does not respect NOLOCK qdisc: the global backlog len is used and the per CPU values are ignored. This change addresses the above, factoring-out the relevant code and using the helpers introduced by the previous patch to fetch the correct backlog len. Fixes: c5ad119f ("net: sched: pfifo_fast use skb_array") Signed-off-by:Paolo Abeni <pabeni@redhat.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- include/net/sch_generic.h 19 additions, 7 deletionsinclude/net/sch_generic.h
- net/sched/sch_cbq.c 1 addition, 5 deletionsnet/sched/sch_cbq.c
- net/sched/sch_drr.c 1 addition, 10 deletionsnet/sched/sch_drr.c
- net/sched/sch_hfsc.c 2 additions, 12 deletionsnet/sched/sch_hfsc.c
- net/sched/sch_htb.c 3 additions, 12 deletionsnet/sched/sch_htb.c
- net/sched/sch_multiq.c 3 additions, 5 deletionsnet/sched/sch_multiq.c
- net/sched/sch_prio.c 2 additions, 6 deletionsnet/sched/sch_prio.c
- net/sched/sch_qfq.c 1 addition, 10 deletionsnet/sched/sch_qfq.c
- net/sched/sch_red.c 1 addition, 2 deletionsnet/sched/sch_red.c
- net/sched/sch_sfb.c 1 addition, 2 deletionsnet/sched/sch_sfb.c
- net/sched/sch_tbf.c 1 addition, 2 deletionsnet/sched/sch_tbf.c
Loading
Please register or sign in to comment