netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ryo Takakura <ryotkkr98@gmail.com>
To: bp@alien8.de, peterz@infradead.org
Cc: boqun.feng@gmail.com, davem@davemloft.net, edumazet@google.com,
	horms@kernel.org, kuba@kernel.org, kuniyu@amazon.com,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	pabeni@redhat.com, ryotkkr98@gmail.com, x86@kernel.org
Subject: Re: request_irq() with local bh disabled
Date: Fri,  7 Mar 2025 21:58:51 +0900	[thread overview]
Message-ID: <20250307125851.54493-1-ryotkkr98@gmail.com> (raw)
In-Reply-To: <20250307115550.GAZ8rexkba5ryV3zk0@fat_crate.local>

Hi Boris and Peter,

On Fri, 7 Mar 2025 12:55:50 +0100, Borislav Petkov wrote:
>On Thu, Mar 06, 2025 at 05:19:12PM +0100, Borislav Petkov wrote:
>> On Thu, Mar 06, 2025 at 02:45:16PM +0100, Eric Dumazet wrote:
>> > Hmmm.. not sure why local_bh is considered held..
>> 
>> Yeah, it looks like it is some crap in tip as current mainline is fine.
>> 
>> Lemme see what I can find there.
>> 
>> Thx and sorry for the noise.
>
>As already mentioned by Mr. Z on the tip-bot message thread, below commit
>breaks lockdep.

Thank you Peter for letting me know.

>Reverting it fixes the issue, ofc.
>
>$ git bisect start
># status: waiting for both good and bad commits
># good: [848e076317446f9c663771ddec142d7c2eb4cb43] Merge tag 'hid-for-linus-2025030501' of git://git.kernel.org/pub/scm/linux/kernel/git/>hid/hid
>git bisect good 848e076317446f9c663771ddec142d7c2eb4cb43
># status: waiting for bad commit, 1 good commit known
># bad: [f4444d22a90c3fb0c825195b4154455d42986f21] Merge remote-tracking branch 'tip/master' into rc5+
>git bisect bad f4444d22a90c3fb0c825195b4154455d42986f21
># bad: [6714630acf3cae8974e62a810389dcb191ac49af] Merge branch into tip/master: 'sched/core'
>git bisect bad 6714630acf3cae8974e62a810389dcb191ac49af
># good: [156a8975430b127b5000b9018cb220fddf633164] Merge branch into tip/master: 'irq/core'
>git bisect good 156a8975430b127b5000b9018cb220fddf633164
># bad: [468fad69db143874eaaeb472816f424e261df570] Merge branch into tip/master: 'locking/core'
>git bisect bad 468fad69db143874eaaeb472816f424e261df570
># good: [f5de95438834a3bc3ad747f67c9da93cd08e5008] irqchip/renesas-rzv2h: Simplify rzv2h_icu_init()
>git bisect good f5de95438834a3bc3ad747f67c9da93cd08e5008
># bad: [5fc1506d33db23894e74caf048ba5591f4986767] rust: lockdep: Remove support for dynamically allocated LockClassKeys
>git bisect bad 5fc1506d33db23894e74caf048ba5591f4986767
># bad: [9b4070d36399ffcadc92c918bd80da036a16faed] locking/lock_events: Add locking events for rtmutex slow paths
>git bisect bad 9b4070d36399ffcadc92c918bd80da036a16faed
># good: [337369f8ce9e20226402cf139c4f0d3ada7d1705] locking/mutex: Add MUTEX_WARN_ON() into fast path
>git bisect good 337369f8ce9e20226402cf139c4f0d3ada7d1705
># bad: [8a9d677a395703ef9075c91dd04066be8a553405] lockdep: Fix wait context check on softirq for PREEMPT_RT
>git bisect bad 8a9d677a395703ef9075c91dd04066be8a553405
># good: [5ddd09863c676935c18c8a13f5afb6d9992cbdeb] locking/rtmutex: Use struct keyword in kernel-doc comment
>git bisect good 5ddd09863c676935c18c8a13f5afb6d9992cbdeb
># first bad commit: [8a9d677a395703ef9075c91dd04066be8a553405] lockdep: Fix wait context check on softirq for PREEMPT_RT
>
>Author: Ryo Takakura <ryotkkr98@gmail.com>
>Date:   Sat Jan 18 14:49:00 2025 +0900
>
>    lockdep: Fix wait context check on softirq for PREEMPT_RT
>    
>    Since commit 0c1d7a2c2d32 ("lockdep: Remove softirq accounting on
>    PREEMPT_RT."), the wait context test for mutex usage within
>    "in softirq context" fails as it references @softirq_context.
>    
>    [    0.184549]   | wait context tests |
>    [    0.184549]   --------------------------------------------------------------------------
>    [    0.184549]                                  | rcu  | raw  | spin |mutex |
>    [    0.184549]   --------------------------------------------------------------------------
>    [    0.184550]                in hardirq context:  ok  |  ok  |  ok  |  ok  |
>    [    0.185083] in hardirq context (not threaded):  ok  |  ok  |  ok  |  ok  |
>    [    0.185606]                in softirq context:  ok  |  ok  |  ok  |FAILED|
>    
>    As a fix, add lockdep map for BH disabled section. This fixes the
>    issue by letting us catch cases when local_bh_disable() gets called
>    with preemption disabled where local_lock doesn't get acquired.
>    In the case of "in softirq context" selftest, local_bh_disable() was
>    being called with preemption disable as it's early in the boot.
>    
>    Signed-off-by: Ryo Takakura <ryotkkr98@gmail.com>
>    Signed-off-by: Boqun Feng <boqun.feng@gmail.com>
>    Link: https://lore.kernel.org/r/20250118054900.18639-1-ryotkkr98@gmail.com

I'm so sorry that the commit caused this problem...
Please let me know if there is anything that I should do.

Sincerely,
Ryo Takakura

>-- 
>Regards/Gruss,
>    Boris.
>
>https://people.kernel.org/tglx/notes-about-netiquette

  reply	other threads:[~2025-03-07 12:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-06 12:24 request_irq() with local bh disabled Borislav Petkov
2025-03-06 13:45 ` Eric Dumazet
2025-03-06 16:19   ` Borislav Petkov
2025-03-07 11:55     ` Borislav Petkov
2025-03-07 12:58       ` Ryo Takakura [this message]
2025-03-07 13:13         ` Borislav Petkov
2025-03-07 13:39           ` Ryo Takakura
2025-03-07 15:57             ` Boqun Feng
2025-03-07 18:33               ` Boqun Feng
2025-03-07 19:29                 ` Boqun Feng
2025-03-07 23:08                   ` Boqun Feng
2025-03-08  8:09                     ` Ryo Takakura
2025-03-07 13:59           ` Peter Zijlstra
2025-03-07 15:50             ` Ryo Takakura

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=20250307125851.54493-1-ryotkkr98@gmail.com \
    --to=ryotkkr98@gmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=bp@alien8.de \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=kuniyu@amazon.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=peterz@infradead.org \
    --cc=x86@kernel.org \
    /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).