Re: [PATCH net] net/sched: Avoid quadratic handle scan in qdisc_alloc_handle
From: Jakub Kicinski <kuba@kernel.org>
Date: 2026-09-15 15:53:05
On Tue, 15 Sep 2026 07:50:54 -0400 Jamal Hadi Salim wrote:
On Mon, Sep 14, 2026 at 10:11 PM Jakub Kicinski [off-list ref] wrote:quoted
On Fri, 11 Sep 2026 10:31:46 -0300 Victor Nogueira wrote:quoted
This is a less intrusive fix meant for backporting; a cleaner approach that uses a per-device IDA over all qdisc handles is planned for net-next.I don't think this is net-worthy in the first place. We have a ton of code under rtnl_lock. We cannot provide any protection from malicious netns admin from overloading the machine.That is the one million dollar question. We labelled this as net for this exact reason. i.e malicious container could overload the whole machine. But it borders on "hardening" (improves performance), so net-next as a target sounds reasonable. It was a coin toss.
IMO any attack from containers / user ns is hardening. If it leads to a crash we take it via net _because it's a crash_ not because user ns can trigger it.
Since we have a few similar "grey" issues in our pending queue - so where's the line for net/net-next?
TBH the line shifts depending on how bad the AI flood is. I tried to document some rules but it only lead to bikesheding. So my recommendation is to write the final fix, without worrying about keeping it simple. And assume the maintainers will redirect to the other tree based on their judgement when applying. With all the AI kiddies these days we routinely apply to a different tree than tagged.
quoted
Nothing against the patch itself, but if you plan to do something else in net-next let's just go with that from the start..We could resend the same patch for net-next, the alternative "proper fix" is more intrusive. See attached.
I'm not sure we have to do this, given Victor's patch already drops the time 50x ?
Another option: Is this worth fixing?
Right, I think it is but IDK if it's worth maintaining state for. IOW Victor's patch would be enough for my taste.