From: Oliver Neukum <oneukum@suse.com>
To: "Ömer Mete Kaya" <omermetekaya0@gmail.com>, netdev@vger.kernel.org
Cc: oneukum@suse.com, andrew+netdev@lunn.ch, davem@davemloft.net,
edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org,
syzbot+04cd90bb99c6ef81a65d@syzkaller.appspotmail.com
Subject: Re: [PATCH net v2] usbnet: fix smp_processor_id() use in preemptible context
Date: Mon, 7 Sep 2026 13:38:53 +0200 [thread overview]
Message-ID: <6e0dbfed-cadd-4274-8165-886725413d0f@suse.com> (raw)
In-Reply-To: <20260905224553.595766-1-omermetekaya0@gmail.com>
On 06.09.26 00:45, Ömer Mete Kaya wrote:
> usbnet_skb_return() and tx_complete() call this_cpu_ptr() before
> disabling IRQs, which triggers a BUG when running with PREEMPT_FULL:
>
> BUG: using smp_processor_id() in preemptible code in tx_complete
>
> Fix by saving IRQs first with local_irq_save(), then calling
> this_cpu_ptr() and using the non-irqsave variants of u64_stats
> update helpers, since IRQs are already disabled at that point.
Hi,
thank you for the patch. However, if the problem is preemption,
when not simply preempt_disable()/peempt_enable()?
Why is it necessary to switch off interrupts?
Regards
Oliver
next prev parent reply other threads:[~2026-09-07 11:38 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 16:54 [PATCH] usbnet: fix smp_processor_id() use in preemptible context Ömer Mete Kaya
2026-09-05 22:45 ` [PATCH net v2] " Ömer Mete Kaya
2026-09-07 11:38 ` Oliver Neukum [this message]
2026-09-07 18:52 ` Ömer Mete Kaya
2026-09-07 20:23 ` David Laight
2026-09-07 21:45 ` [PATCH net v4] " Ömer Mete Kaya
2026-09-09 21:47 ` netdev-bot+sashiko
2026-09-10 9:01 ` David Laight
2026-09-07 19:05 ` [PATCH] " Ömer Mete Kaya
2026-09-08 3:43 ` [PATCH net v2] " netdev-bot+sashiko
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=6e0dbfed-cadd-4274-8165-886725413d0f@suse.com \
--to=oneukum@suse.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=omermetekaya0@gmail.com \
--cc=pabeni@redhat.com \
--cc=syzbot+04cd90bb99c6ef81a65d@syzkaller.appspotmail.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