From: Jamal Hadi Salim <jhs@mojatatu.com>
To: "Toke Høiland-Jørgensen" <toke@toke.dk>
Cc: netdev@vger.kernel.org, "Jiri Pirko" <jiri@resnulli.us>,
"David S . Miller" <davem@davemloft.net>,
"Eric Dumazet" <edumazet@kernel.org>,
"Jakub Kicinski" <kuba@kernel.org>,
"Paolo Abeni" <pabeni@redhat.com>,
"Simon Horman" <horms@kernel.org>,
"Victor Nogueira" <victor@mojatatu.com>,
"Björn Töpel" <bjorn@kernel.org>,
cake@lists.bufferbloat.net, Sashiko <sashiko-bot@kernel.org>
Subject: [Cake] Re: [PATCH net-next v7 1/4] net/sched: cake, fq_codel: return the classifier result to the caller
Date: Mon, 19 Oct 2026 17:05:22 -0400 [thread overview]
Message-ID: <CAM0EoM=6joWtYQdkw0KheH0sEx0r1P7_+6aEt3235OQZSxD9Mg@mail.gmail.com> (raw)
In-Reply-To: <87wlrdwof7.fsf@toke.dk>
On Mon, Oct 19, 2026 at 2:11 PM Toke Høiland-Jørgensen <toke@toke.dk> wrote:
>
> Jamal Hadi Salim <jhs@mojatatu.com> writes:
>
> > The Fix:
> > cake and fq_codel run an optional external classifier from their enqueue
> > path and then compute the flow hash inside the helper. Have the helper
> > return the filter's overrides (cake) or a 1-based flow index or a request
> > to hash (fq_codel) instead, so the caller owns the flow selection.
> >
> > This is preparation for the accounting changes that follow. Packet
> > classification and flow selection are unchanged.
>
> It's not clear to me why this change is needed at all for fq_codel?
> fq_codel_hash just does a reciprocal_scale() of the skb hash, it doesn't
> mutate any qdisc state. So why can't fq_codel_classify not just stay as
> it is?
It is not functionaly needed for fq_codel, it is more because these
two are cousins and simplifies subsequent patches.
Note in patch 4 we force the same semantics on cake as in fq_codel
(classifier decides the drop, the caller owns flow selection). Keeping
fq_codel's classify the same makes patch 3 hunks in the two files
similar. There is another reason: the old helper encoded "drop" as a
magic return and carried the 1-based +1 arithmetic on every return
path.
In any case, unless you feel strongly i would rather keep it.
cheers,
jamal
next prev parent reply other threads:[~2026-10-19 21:05 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-19 16:00 [Cake] [PATCH net-next v7 0/4] net/sched: cap the accounted backlog before it can wrap Jamal Hadi Salim
2026-10-19 16:00 ` [Cake] [PATCH net-next v7 1/4] net/sched: cake, fq_codel: return the classifier result to the caller Jamal Hadi Salim
2026-10-19 18:11 ` [Cake] " Toke Høiland-Jørgensen
2026-10-19 21:05 ` Jamal Hadi Salim [this message]
2026-10-20 8:58 ` Toke Høiland-Jørgensen
2026-10-20 10:06 ` Jamal Hadi Salim
2026-10-19 16:00 ` [Cake] [PATCH net-next v7 2/4] net/sched: cake: use a dedicated split-GSO list iterator Jamal Hadi Salim
2026-10-19 18:11 ` [Cake] " Toke Høiland-Jørgensen
2026-10-19 16:00 ` [Cake] [PATCH net-next v7 3/4] net/sched: cap the accounted backlog before it can wrap Jamal Hadi Salim
2026-10-19 18:20 ` [Cake] " Toke Høiland-Jørgensen
2026-10-19 21:08 ` Jamal Hadi Salim
2026-10-19 16:00 ` [Cake] [PATCH net-next v7 4/4] net/sched: cake: hash before segmenting and reject an overlong split Jamal Hadi Salim
2026-10-19 18:32 ` [Cake] " Toke Høiland-Jørgensen
2026-10-19 21:35 ` Jamal Hadi Salim
2026-10-20 8:47 ` Toke Høiland-Jørgensen
2026-10-20 10:08 ` Jamal Hadi Salim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://lists.bufferbloat.net/postorius/lists/cake.lists.bufferbloat.net/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAM0EoM=6joWtYQdkw0KheH0sEx0r1P7_+6aEt3235OQZSxD9Mg@mail.gmail.com' \
--to=jhs@mojatatu.com \
--cc=bjorn@kernel.org \
--cc=cake@lists.bufferbloat.net \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=horms@kernel.org \
--cc=jiri@resnulli.us \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=sashiko-bot@kernel.org \
--cc=toke@toke.dk \
--cc=victor@mojatatu.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox