[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87346ijbs9.fsf@toke.dk>
Date: Thu, 13 Nov 2025 14:35:18 +0100
From: Toke Høiland-Jørgensen <toke@...e.dk>
To: Xiang Mei <xmei5@....edu>, security@...nel.org
Cc: netdev@...r.kernel.org, cake@...ts.bufferbloat.net, bestswngs@...il.com
Subject: Re: [PATCH net v3] net/sched: sch_cake: Fix incorrect qlen
reduction in cake_drop
Xiang Mei <xmei5@....edu> writes:
> There is still one problem I am not very sure since I am not very
> experienced with cake and gso. It's about the gso branch [1]. The slen
> is the lenth added to the cake sch and that branch uses
> `qdisc_tree_reduce_backlog(sch, 1-numsegs, len-slen);` to inform the
> parent sched. However, when we drop the packet, it could be probmatic
> since we should reduce slen instead of len. Is this a potential
> problem?
Hmm, no I think it's fine? The qdisc_tree_reduce_backlog(sch, 1-numsegs,
len-slen) *increases* the backlog with the difference between the
original length and the number of new segments. And then we *decrease*
the backlog with the number of bytes we dropped.
The compensation we're doing is for the backlog update of the parent,
which is still using the original packet length regardless of any
splitting, so that doesn't change the compensation value.
-Toke
Powered by blists - more mailing lists