From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mail.toke.dk; dkim=pass header.d=gmx.de header.i=moeller0@gmx.de header.a=rsa-sha256 header.s=s31663417 header.b=dPAHRuWQ; arc=none (Message is not ARC signed); dmarc=pass (Used From Domain Record) header.from=gmx.de policy.dmarc=quarantine Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) by mail.toke.dk (Postfix) with ESMTPS id A6CA116FA138 for ; Fri, 25 Sep 2026 16:03:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.de; s=s31663417; t=1790344983; x=1790949783; i=moeller0@gmx.de; bh=vpZb0bG7viHI4T2NX9PNE2UWQJKoTmRIhUmmOaip0lM=; h=X-UI-Sender-Class:Content-Type:Mime-Version:Subject:From: In-Reply-To:Date:Cc:Content-Transfer-Encoding:Message-Id: References:To:cc:content-transfer-encoding:content-type:date:from: message-id:mime-version:reply-to:subject:to; b=dPAHRuWQD6MnPnHxxxmBSCiVC/kGqxRiByFCoQMEQ3fRXSP4XwyEL1neVQ51GI4X y5qnqIjru4Tdahzipp4XhCEulnAKSA6nPsVWwy7gto+9f7EMxcY3gaokVpT8IEcDW TTSQGIOvqrDB9gW0hABzqb37KTarSOMEt03LtlNI4EHu/JZX0gvXd45f35PU6ddjL F/8839/TA0oVLcUziuv4IRph8XF4365DZrN69IiKsUktbTNcN2EUuT/lQvqtdbRgm 440K5EOGhLvsXVYURcjO/Q3qGrNs1aLfiK/OwmBFfuxdL+w3fdIKkM62DDtvcf5ot AXx6c2Ktix6ig8dstA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from client.hidden.invalid by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MWzfv-1xGqhb48hF-00V7Hg; Fri, 25 Sep 2026 16:03:03 +0200 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.700.51.1.3\)) From: Sebastian Moeller In-Reply-To: Date: Fri, 25 Sep 2026 16:02:50 +0200 Cc: Jamal Hadi Salim , netdev@vger.kernel.org, =?utf-8?Q?Toke_H=C3=B8iland-J=C3=B8rgensen?= , cake@lists.bufferbloat.net, Jiri Pirko , "David S . Miller" , Jakub Kicinski , Paolo Abeni , Simon Horman , Victor Nogueira , hybris , Sashiko Content-Transfer-Encoding: quoted-printable Message-Id: <67EA1744-69D7-4A64-9117-D6A79A3A93E4@gmx.de> References: <68BE1514-828D-4184-84E4-90F2EB3F035D@gmx.de> To: Eric Dumazet X-Mailer: Apple Mail (2.3864.700.51.1.3) X-Provags-ID: V03:K1:TPNWxxqYuZ6UoA4G6VddTe35jFlzgXE0MhMA/R7I/v65eDI7btS gX0aZsGkCi04yj0hB1S69w4ekoOLPOOWIeAV8om2BLshl0drRKnan6NsBoNnfO7JXrrt6Cs jHPgK29Urr5RiBPGW6+02lJERWuLXq37fXEA5HAGkofGSaYluN+/gWdtwNjACvmNgYYpJP6 aYIco7n+xic5SSJ/IgqfQ== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:OLOrq8eWaDg=;1A66JA/jPQEGl/725FaSBzrAX9Y DOo94KZMst4ujZ5LrBdt2x+cxRA10mACXnUWqo8/YS99d2LeqH3RfBf5ZiCDVIuZGmM1pytKg nWkVegEthGU/IDqaS/MBnDDLBhHHWhWnjERimBb+BptFc8YiL+R1KmhJWBsUyQabn4DqiLOUC 4PB9xWEeqK3zimWX6Acyd0bI6geQhTjbi2ssgro8oZibbclkuSvUZ91lBP1eLXC2SUcd7+26X AfS57TzcNVnK+rCy6J+XADc4Nma1xodnTOeP1xiyZOMYwb+KzdurfUGLaPiEtQBr/AogOOqYG YnLechbZFhIQN2HTtttZsNEysZuqGfRT6Pi+otrtYm5CI0RxW7g+sqADa+W/78SEj/UOmrRgX qdZzUQQBo9vUOBWWamP0wcNtv62culQYrjPhRfIsqYNHxXVpy5dcxrxGv8fi90xsnLR10qD+3 LZ6RYtQ2Key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tz V33c44Hq5L6P0/RZj8AlN5wpTmfIa+Brufk1PatbIcDdgoehqxQTe2NuNwRiMqY5bjpCbqmdQ 1i9N+GvxN7j7APAyKePwPoF4Cc6u/p1Z0SVgd4XmHzd6jn6kDX89XdWbH5gcel/iDNp2XvSuV 3pp+rtzlA1DOAkUVgccF7LyjU+paybFjfsQlkrR9iDRsjFHEkv+oGixWnQ6qEvLR1KyHdTR8v u58jKcBK5sTYWX0U972qk8dzPe4WLqugTPTY4aXcHr5ApKqASgzqchAl03dpQuM3lfg1JscJF fdCqVLVcOWNVa8H1JD73iXxG4/pDnF9/FGROdZxxOiIsac5nwM1GZrFvjK89ba2BZzXz4HA3j yb64aqbeOpSNM4UAucjEke9OZGEywBMNAqpXDRdjvPTEo/hx7NwbHZp+CnFWwnWXhm45u/Nsl BY20W/TUuz61ratDcHlxLS2C3v5jjeEp/1Rvi3UntdKHyeIHP9/iHRqy6CzPkWf9kRVdjpsBX 7m1lSFqyrxE7d6Y3zQWaayxbhwz4REusQx7PMJ28IlmFY8JsnES96BD93FLIRv0RoCKcv7WYS cFH8lkItSUKmbwFGqiPv2BXBJrZz2Ttc24y+q6X5pY/vOrUqXy2CdxYEnDRpULkfSMUnTkJi4 olUAe9C8wVHnUL0QALtrDaQ6Fs7GqlMMgEFjapWxPr0A2TSvXfahavqwPiPma14Gh/UiWZB0v u2G8oGy9MCxGk/5mm9jhivSsQizBXR+V0HT75PZnr/slx3ggWPTkwSxEUm0 Message-ID-Hash: D5NMFG3P4FOV5CJCHPHZSTBKICYSDBXA X-Message-ID-Hash: D5NMFG3P4FOV5CJCHPHZSTBKICYSDBXA X-MailFrom: moeller0@gmx.de X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list Subject: [Cake] Re: [PATCH net-next] net/sched: fq_codel, cake: widen backlogs to u64 List-Id: Cake - FQ_codel the next generation Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Hi Eric, > On Sep 25, 2026, at 15:43, Eric Dumazet wrote: >=20 > On Fri, Sep 25, 2026 at 3:30=E2=80=AFPM Sebastian Moeller = wrote: >>=20 >> Hi Eric, >>=20 >>=20 >>> On Sep 25, 2026, at 15:03, Eric Dumazet via Cake = wrote: >>>=20 >>> On Fri, Sep 25, 2026 at 1:28=E2=80=AFPM Jamal Hadi Salim = wrote: >>>>=20 >>>> On Fri, Sep 25, 2026 at 5:13=E2=80=AFAM Eric Dumazet = wrote: >>>>>=20 >>>>> On Fri, Sep 25, 2026 at 10:54=E2=80=AFAM Jamal Hadi Salim = wrote: >>>>>>=20 >>>>>> This is a follow-up to commit 8f735d64382d ("net/sched: bound >>>>>> qdisc_pkt_len to prevent qdisc soft lockup"), which capped >>>>>> qdisc_pkt_len() at QDISC_PKT_LEN_MAX (1 MiB). That cap bounds the = stab >>>>>> amplifier but leaves the per-flow backlog counter u32: >>>>>> fq_codel_enqueue() accumulates qdisc_pkt_len(skb) into = q->backlogs[idx], >>>>>> so a flow can still accumulate 4096 packets of 1 MiB each and = wrap the >>>>>> counter mod 2^32. After a wrap, fq_codel_drop() sees a tiny = maxbacklog >>>>>> and drops from an almost-empty flow, and the dequeue-side = subtractions >>>>>> corrupt the counter further. >>>>>>=20 >>>>>> Widen the fq_codel backlogs table, the fat-flow scan = (maxbacklog/len) and >>>>>> the drop threshold to u64. fq_codel is not lockless: every writer = runs >>>>>> under the root qdisc lock, so plain u64 arithmetic keeps the = WRITE_ONCE >>>>>> publish / READ_ONCE-consume pattern. The dump path >>>>>> (fq_codel_dump_class_stats) stays a lockless stat-only read. >>>>>>=20 >>>>>> CAKE accumulates the same generic qdisc_pkt_len(skb) into its = per-flow >>>>>> b->backlogs[] and per-tin b->tin_backlog and consumes the values = for >>>>>> longest-flow pruning (cake_heapify/cake_heapify_up) and for the = shaper >>>>>> staleness check, so it shares the bug. Widen those counters and = the heap >>>>>> comparison locals to u64; the class/tin stats keep exporting the = low 32 >>>>>> bits through the unchanged uAPI fields. >>>>>>=20 >>>>>> Conditions to recreate the bug: CAP_NET_ADMIN in a user = namespace; >>>>>> CONFIG_NET_SCH_FQ_CODEL=3Dy. >>>>>>=20 >>>>>> ip tuntap add tun0 mode tun >>>>>> ip link set tun0 txqueuelen 32 up >>>>>> ip addr add 10.99.0.1/24 dev tun0 >>>>>> tc qdisc add dev tun0 root handle 1: stab overhead 2000000000 \ >>>>>> fq_codel flows 1 limit 4200 ecn drop_batch 4096 >>>>>> # hold the tun fd open without reading (IFF_BACKPRESSURE) so the = qdisc >>>>>> # backlog persists, then send at least 4300 packets (the wrap = starts >>>>>> # at 4096 resident; the over-limit drop that reads the wrapped >>>>>> # threshold fires past the 4200 limit): backlogs[0] wraps at 4096 = x >>>>>> # 1 MiB and the fat-flow threshold reads the wrapped value. >>>>>>=20 >>>>>> With a 1 MiB qdisc_pkt_len cap the counter wraps at 4096 resident >>>>>> packets. At limit 4200 the first over-limit enqueue (the 4201st) = sees a >>>>>> wrapped 105 MiB (half-backlog threshold 52 MiB, a ~52 packet drop = burst), >>>>>> where the u64 counter sees 4201 MiB (threshold 2100 MiB, a ~2100 = packet >>>>>> drop burst). >>>>>>=20 >>>>>> Reported-by: Sashiko (nipa) >>>>>> Closes: = https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20260818101130.16203-1= -jhs@mojatatu.com >>>>>> Link: = https://lore.kernel.org/netdev/20260818101130.16203-1-jhs@mojatatu.com/ >>>>>> Tested-by: hybris >>>>>> Signed-off-by: Jamal Hadi Salim >>>>>> --- >>>>>=20 >>>>> This makes no sense. >>>>>=20 >>>>=20 >>>> As absurd as it looks that code is reachable ;-> >>>>=20 >>>>> These qdisc have been developped to address bufferbloat issues. >>>>>=20 >>>>> Storing 4GB in a qdisc is absolutely insane. >>>>>=20 >>>>=20 >>>> The counter wrap is not because we stored 4GB, rather it is because >>>> "tc .. stab overhead ..." inflates qdisc_pkt_len() for a 64B pkt to >>>> 1MB. So ~4K packets (put in other words a few "real" KB) makes that >>>> backlog[0] cross 2^32. >>>=20 >>> Kill this stuff ? Who is still using this, for what reason ? >>=20 >> tc-stab? Same as before, if you need want to model a remote = bottleneck with a local traffic shaper tc-stab is the generic solution = (off the top of my head I only can enumerate cake as having its own = traffic shaper that handles overheads). >> One could argue that the "virtual" length should be accounted against = cake's memlimit or fq-codel's memory_limit somehow... >> In sane?/typical configurations overhead is expected to stay = relatively small, so this would not limit the actual queue size too = much, while potentially silencing this issue. >=20 > linux qdisc are in the fast path, for nearly all packets sent over = this planet. Tip of the head to the linux network experts that enabled that and that = take care of it being efficient! > They aleady consume GW of energy. >=20 > Modeling / network emulation should incur zero cost on these > production grade qdisc. It is not modeling in a scientific sense (sorry I used inappropriate = terminology here), but simply the fact that to shape traffic to avoid = filling remote queues one needs to be able to take the properties of = that remote queue/interface/link-layer into account. And that can be surprisingly close by. Last time I looked the kernel on = say eth0 added the 14 bytes of ethernet related overhead it handled = itself to the packet size on top of the payload (no complaints that = makes sense) but that is insufficient to properly traffic shape e.g. the = same ethernet interface... (as the relevant ethernet L1-frame overhead = contains more bytes, like the FCS, preamble and SFD). And that gets = worse with stuff like DSL, cable or fibre modems that are connected via = ethernet to a linux router. >=20 > netem could be one answer, I do not know, or a special > CONFIG_NET_SCHED_EXPENSIVE_EMULATION Well, tc-stab (or cake's overhead accounting) is already optional, so = only those incur the cost that actually use it (and only those users are = affected by the reported issue, it took tc-stab to cause the problem and = arguably in a configuration that is "insane").=20 I might be trying to explain the internet here to people that make the = internet work, so apologies in advance but I want to make this as = explicit as I can. TTraffic shaping without proper overhead accounting will not work as = expected (at least if the expectation is that the traffic shaper will = honor the set gross shaper rate). For a fixed packet size the lack over = overhead accounting can be papered over with reducing the shaper rate, = but the amount of the required "over-shaping" depends on packet size = (smaller packets require more over-shaping), so generally that is sub = optimal, because either the shaper's guarantee is brittle or the = over-shaping quite extreme (think the header to payload ration of = minimally- and MTU-sized packets). All I am saying is, we do still have use cases for tc-stab and proper = overhead accounting, at least on the leafs of the network like home = internet links. >=20 >>=20 >> I might be off my rocker, in which has ignore (or preferably = enlighten me).