Commit b3d7e2b2 authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

net_sched: sch_codel: defer skb freeing in codel_change()

codel_change() can use rtnl_qdisc_drop()
to defer expensive skb freeing after locks are released.

codel_reset() already has support for deferred skb freeing
because it uses qdisc_reset_queue()
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f9aed311
...@@ -174,7 +174,7 @@ static int codel_change(struct Qdisc *sch, struct nlattr *opt) ...@@ -174,7 +174,7 @@ static int codel_change(struct Qdisc *sch, struct nlattr *opt)
dropped += qdisc_pkt_len(skb); dropped += qdisc_pkt_len(skb);
qdisc_qstats_backlog_dec(sch, skb); qdisc_qstats_backlog_dec(sch, skb);
qdisc_drop(skb, sch); rtnl_qdisc_drop(skb, sch);
} }
qdisc_tree_reduce_backlog(sch, qlen - sch->q.qlen, dropped); qdisc_tree_reduce_backlog(sch, qlen - sch->q.qlen, dropped);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment