From: Florian Westphal <fw@strlen.de>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: netfilter-devel@vger.kernel.org, coreteam@netfilter.org,
linux-rt-devel@lists.linux.dev,
Pablo Neira Ayuso <pablo@netfilter.org>,
Jozsef Kadlecsik <kadlec@netfilter.org>,
Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [PATCH nf-next v2 3/3] netfilter: nft_set_pipapo: Use nested-BH locking for nft_pipapo_scratch
Date: Sat, 16 Aug 2025 16:25:44 +0200 [thread overview]
Message-ID: <aKCU6GGY05WO3p_7@strlen.de> (raw)
In-Reply-To: <20250815160937.1192748-4-bigeasy@linutronix.de>
Sebastian Andrzej Siewior <bigeasy@linutronix.de> wrote:
> @@ -1170,20 +1170,18 @@ nft_pipapo_avx2_lookup(const struct net *net, const struct nft_set *set,
> }
>
> m = rcu_dereference(priv->match);
> -
> + scratch = *raw_cpu_ptr(m->scratch);
> + if (unlikely(!scratch)) {
> + local_bh_enable();
> + return false;
The function has been changed upstream to return a pointer.
> + }
> + __local_lock_nested_bh(&scratch->bh_lock);
> /* Note that we don't need a valid MXCSR state for any of the
> * operations we use here, so pass 0 as mask and spare a LDMXCSR
> * instruction.
> */
> kernel_fpu_begin_mask(0);
Not sure this is correct. If RT allows to migrate in BH before
the local lock is taken, then the if (unlikely(!irq_fpu_usable()))
check needs to be done after the local lock was taken, no?
I will place a pending pipapo change in the nf-next:testing
branch shortly in case you need to resend.
If its fine as-is, I can also rebase the pending pipapo_avx2 patches.
Let me know.
next prev parent reply other threads:[~2025-08-16 14:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-15 16:09 [PATCH nf-next v2 0/3] netfilter: nft_set_pipapo: Use nested-BH locking for nft_pipapo_scratch Sebastian Andrzej Siewior
2025-08-15 16:09 ` [PATCH nf-next v2 1/3] netfilter: nft_set_pipapo: Store real pointer, adjust later Sebastian Andrzej Siewior
2025-08-15 16:09 ` [PATCH nf-next v2 2/3] netfilter: nft_set_pipapo_avx2: Drop the comment regarding protection Sebastian Andrzej Siewior
2025-08-15 16:09 ` [PATCH nf-next v2 3/3] netfilter: nft_set_pipapo: Use nested-BH locking for nft_pipapo_scratch Sebastian Andrzej Siewior
2025-08-16 14:25 ` Florian Westphal [this message]
2025-08-18 9:11 ` Sebastian Andrzej Siewior
2025-08-18 9:24 ` Florian Westphal
2025-08-18 9:56 ` Sebastian Andrzej Siewior
2025-08-19 15:49 ` kernel test robot
2025-08-21 6:03 ` kernel test robot
2025-08-16 15:15 ` [PATCH nf-next v2 0/3] " Florian Westphal
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aKCU6GGY05WO3p_7@strlen.de \
--to=fw@strlen.de \
--cc=bigeasy@linutronix.de \
--cc=coreteam@netfilter.org \
--cc=kadlec@netfilter.org \
--cc=linux-rt-devel@lists.linux.dev \
--cc=netfilter-devel@vger.kernel.org \
--cc=pablo@netfilter.org \
--cc=tglx@linutronix.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.