netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Simon Horman <horms@kernel.org>
To: Justin Iurman <justin.iurman@uliege.be>
Cc: netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com,
	kuba@kernel.org, pabeni@redhat.com, kuniyu@amazon.com,
	Alexei Starovoitov <alexei.starovoitov@gmail.com>,
	Eduard Zingerman <eddyz87@gmail.com>, bpf <bpf@vger.kernel.org>,
	Stanislav Fomichev <stfomichev@gmail.com>,
	Sebastian Sewior <bigeasy@linutronix.de>,
	Andrea Mayer <andrea.mayer@uniroma2.it>,
	Stefano Salsano <stefano.salsano@uniroma2.it>,
	Paolo Lungaroni <paolo.lungaroni@uniroma2.it>
Subject: Re: [PATCH net v3] net: lwtunnel: disable BHs when required
Date: Mon, 21 Apr 2025 14:44:43 +0100	[thread overview]
Message-ID: <20250421134443.GG2789685@horms.kernel.org> (raw)
In-Reply-To: <20250416160716.8823-1-justin.iurman@uliege.be>

On Wed, Apr 16, 2025 at 06:07:16PM +0200, Justin Iurman wrote:
> v3:
> - removed unrelated code cleanups
> v2:
> - https://lore.kernel.org/netdev/20250415173239.39781-1-justin.iurman@uliege.be/
> v1:
> - https://lore.kernel.org/netdev/20250403083956.13946-1-justin.iurman@uliege.be/

Hi Justin,

There is probably no need to resend because of this,
but the changelog above belongs below the scissors ("---")
which will preserve it in mailing list archives and so on,
while excluding it from git history.

> 
> In lwtunnel_{output|xmit}(), dev_xmit_recursion() may be called in
> preemptible scope for PREEMPT kernels. This patch disables BHs before
> calling dev_xmit_recursion(). BHs are re-enabled only at the end, since
> we must ensure the same CPU is used for both dev_xmit_recursion_inc()
> and dev_xmit_recursion_dec() (and any other recursion levels in some
> cases) in order to maintain valid per-cpu counters.
> 
> Reported-by: Alexei Starovoitov <alexei.starovoitov@gmail.com>
> Closes: https://lore.kernel.org/netdev/CAADnVQJFWn3dBFJtY+ci6oN1pDFL=TzCmNbRgey7MdYxt_AP2g@mail.gmail.com/
> Reported-by: Eduard Zingerman <eddyz87@gmail.com>
> Closes: https://lore.kernel.org/netdev/m2h62qwf34.fsf@gmail.com/
> Fixes: 986ffb3a57c5 ("net: lwtunnel: fix recursion loops")
> Signed-off-by: Justin Iurman <justin.iurman@uliege.be>

I agree that this patch is in keeping with the solution discussed
at the links above.

Reviewed-by: Simon Horman <horms@kernel.org>

  reply	other threads:[~2025-04-21 13:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-16 16:07 [PATCH net v3] net: lwtunnel: disable BHs when required Justin Iurman
2025-04-21 13:44 ` Simon Horman [this message]
2025-04-22 23:59 ` Jakub Kicinski

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=20250421134443.GG2789685@horms.kernel.org \
    --to=horms@kernel.org \
    --cc=alexei.starovoitov@gmail.com \
    --cc=andrea.mayer@uniroma2.it \
    --cc=bigeasy@linutronix.de \
    --cc=bpf@vger.kernel.org \
    --cc=davem@davemloft.net \
    --cc=eddyz87@gmail.com \
    --cc=edumazet@google.com \
    --cc=justin.iurman@uliege.be \
    --cc=kuba@kernel.org \
    --cc=kuniyu@amazon.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=paolo.lungaroni@uniroma2.it \
    --cc=stefano.salsano@uniroma2.it \
    --cc=stfomichev@gmail.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;
as well as URLs for NNTP newsgroup(s).