From 150061a2065192d77a4f6518b6238be81dfb8321 Mon Sep 17 00:00:00 2001 From: Eric Dumazet Date: Tue, 12 May 2026 09:48:59 +0000 Subject: [PATCH] net/sched: fq_codel: local packets no longer count against memory limit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Commit 95b58430abe7 ("fq_codel: add memory limitation per queue") claimed that the 32Mb default was "reasonable even for heavy duty usages." In practice, this is not the case. Packets that are associated with local sockets sk_wmem_alloc do not really need additional memory control. Signed-off-by: Eric Dumazet Reviewed-by: Toke Høiland-Jørgensen Link: https://patch.msgid.link/20260512094859.3673997-3-edumazet@google.com Signed-off-by: Jakub Kicinski --- net/sched/sch_fq_codel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/sched/sch_fq_codel.c b/net/sched/sch_fq_codel.c index 1b1de693d4c6..71107dc52be7 100644 --- a/net/sched/sch_fq_codel.c +++ b/net/sched/sch_fq_codel.c @@ -212,7 +212,7 @@ static int fq_codel_enqueue(struct sk_buff *skb, struct Qdisc *sch, q->new_flow_count++; WRITE_ONCE(flow->deficit, q->quantum); } - get_codel_cb(skb)->mem_usage = skb->truesize; + get_codel_cb(skb)->mem_usage = is_skb_wmem(skb) ? 0 : skb->truesize; q->memory_usage += get_codel_cb(skb)->mem_usage; memory_limited = q->memory_usage > q->memory_limit; qdisc_qlen_inc(sch); -- 2.47.3