public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Unexpected lockdep selftest failures
@ 2024-11-22 20:18 Bart Van Assche
  2024-11-24 21:33 ` Palmer Dabbelt
  2024-11-26 22:23 ` Boqun Feng
  0 siblings, 2 replies; 4+ messages in thread
From: Bart Van Assche @ 2024-11-22 20:18 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar, Will Deacon, Waiman Long; +Cc: linux-kernel

Hi,

With the for-next branch of this tree: git://git.kernel.dk/linux-block
(commit 12ab2c13ca77 ("Merge branch 'for-6.13/block' into for-next")) I
see the following:


[    0.887603][    T0] 
--------------------------------------------------------------------------
[    0.888763][    T0]   | Wound/wait tests |
[    0.889310][    T0]   ---------------------
[    0.889867][    T0]                   ww api failures:  ok  |FAILED| 
ok  |
[    0.892597][    T0]                ww contexts mixing:  ok  |  ok  |
[    0.894638][    T0]              finishing ww context:  ok  |  ok  | 
ok  |  ok  |
[    0.898020][    T0]                locking mismatches:  ok  |  ok  | 
ok  |
[    0.900689][    T0]                  EDEADLK handling:  ok  |  ok  | 
ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |
[    0.908172][    T0]            spinlock nest unlocked:  ok  |
[    0.909484][    T0]                spinlock nest test:  ok  |
[    0.910902][    T0] 
-----------------------------------------------------
[    0.911824][    T0]                                  |block | try 
|context|
[    0.912970][    T0] 
-----------------------------------------------------
[    0.913890][    T0]                           context:  ok  |  ok  | 
ok  |
[    0.916613][    T0]                               try:  ok  |  ok  | 
ok  |
[    0.919235][    T0]                             block:  ok  |  ok  | 
ok  |
[    0.921852][    T0]                          spinlock:  ok  |  ok 
|FAILED|
[    0.924666][    T0] 
--------------------------------------------------------------------------
[    0.925852][    T0]   | queued read lock tests |
[    0.926506][    T0]   ---------------------------
[    0.927132][    T0]       hardirq read-lock/lock-read:  ok  |
[    0.928496][    T0]       hardirq lock-read/read-lock:  ok  |
[    0.929860][    T0]                 hardirq inversion:  ok  |
[    0.931269][    T0]   --------------------
[    0.931827][    T0]   | fs_reclaim tests |
[    0.932383][    T0]   --------------------
[    0.932932][    T0]                   correct nesting:  ok  |
[    0.934252][    T0]                     wrong nesting:  ok  |
[    0.935518][    T0]                 protected nesting:  ok  |
[    0.936784][    T0] 
--------------------------------------------------------------------------
[    0.937936][    T0]   | wait context tests |
[    0.938516][    T0] 
--------------------------------------------------------------------------
[    0.939661][    T0]                                  | rcu  | raw  | 
spin |mutex |
[    0.940646][    T0] 
--------------------------------------------------------------------------
[    0.941798][    T0]                in hardirq context:  ok  |  ok  | 
ok  |  ok  |
[    0.944946][    T0] in hardirq context (not threaded):  ok  |  ok  | 
ok  |  ok  |
[    0.948072][    T0]                in softirq context:  ok  |  ok  | 
ok  |  ok  |
[    0.951206][    T0]                    in RCU context:  ok  |  ok  | 
ok  |  ok  |
[    0.954345][    T0]                 in RCU-bh context:  ok  |  ok  | 
ok  |  ok  |
[    0.957477][    T0]              in RCU-sched context:  ok  |  ok  | 
ok  |  ok  |
[    0.960612][    T0]           in RAW_SPINLOCK context:  ok  |  ok  | 
ok  |  ok  |
[    0.963927][    T0]               in SPINLOCK context:  ok  |  ok  | 
ok  |  ok  |
[    0.967252][    T0]                  in MUTEX context:  ok  |  ok  | 
ok  |  ok  |
[    0.970571][    T0] 
--------------------------------------------------------------------------
[    0.971702][    T0]   | local_lock tests |
[    0.972422][    T0]   ---------------------
[    0.972965][    T0]           local_lock inversion  2:  ok  |
[    0.974319][    T0]           local_lock inversion 3A:  ok  |
[    0.975708][    T0]           local_lock inversion 3B:  ok  |
[    0.977106][    T0]       hardirq_unsafe_softirq_safe:  ok  |
[    0.978595][    T0] 
--------------------------------------------------------------------------
[    0.979723][    T0]   | lockdep_set_subclass() name test|
[    0.980424][    T0]   -----------------------------------
[    0.981123][    T0]     compare name before and after:  ok  |
[    0.982423][    T0] 
-----------------------------------------------------------------
[    0.983434][    T0] BUG:   2 unexpected failures (out of 395) - 
debugging disabled! |
[    0.984441][    T0] 
-----------------------------------------------------------------


Is this a known issue?

Thanks,

Bart.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Unexpected lockdep selftest failures
  2024-11-22 20:18 Unexpected lockdep selftest failures Bart Van Assche
@ 2024-11-24 21:33 ` Palmer Dabbelt
  2024-11-26 22:23 ` Boqun Feng
  1 sibling, 0 replies; 4+ messages in thread
From: Palmer Dabbelt @ 2024-11-24 21:33 UTC (permalink / raw)
  To: bvanassche; +Cc: peterz, mingo, Will Deacon, longman, linux-kernel

On Fri, 22 Nov 2024 12:18:40 PST (-0800), bvanassche@acm.org wrote:
> Hi,
>
> With the for-next branch of this tree: git://git.kernel.dk/linux-block
> (commit 12ab2c13ca77 ("Merge branch 'for-6.13/block' into for-next")) I
> see the following:
>
>
> [    0.887603][    T0]
> --------------------------------------------------------------------------
> [    0.888763][    T0]   | Wound/wait tests |
> [    0.889310][    T0]   ---------------------
> [    0.889867][    T0]                   ww api failures:  ok  |FAILED|
> ok  |
> [    0.892597][    T0]                ww contexts mixing:  ok  |  ok  |
> [    0.894638][    T0]              finishing ww context:  ok  |  ok  |
> ok  |  ok  |
> [    0.898020][    T0]                locking mismatches:  ok  |  ok  |
> ok  |
> [    0.900689][    T0]                  EDEADLK handling:  ok  |  ok  |
> ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |
> [    0.908172][    T0]            spinlock nest unlocked:  ok  |
> [    0.909484][    T0]                spinlock nest test:  ok  |
> [    0.910902][    T0]
> -----------------------------------------------------
> [    0.911824][    T0]                                  |block | try
> |context|
> [    0.912970][    T0]
> -----------------------------------------------------
> [    0.913890][    T0]                           context:  ok  |  ok  |
> ok  |
> [    0.916613][    T0]                               try:  ok  |  ok  |
> ok  |
> [    0.919235][    T0]                             block:  ok  |  ok  |
> ok  |
> [    0.921852][    T0]                          spinlock:  ok  |  ok
> |FAILED|
> [    0.924666][    T0]
> --------------------------------------------------------------------------
> [    0.925852][    T0]   | queued read lock tests |
> [    0.926506][    T0]   ---------------------------
> [    0.927132][    T0]       hardirq read-lock/lock-read:  ok  |
> [    0.928496][    T0]       hardirq lock-read/read-lock:  ok  |
> [    0.929860][    T0]                 hardirq inversion:  ok  |
> [    0.931269][    T0]   --------------------
> [    0.931827][    T0]   | fs_reclaim tests |
> [    0.932383][    T0]   --------------------
> [    0.932932][    T0]                   correct nesting:  ok  |
> [    0.934252][    T0]                     wrong nesting:  ok  |
> [    0.935518][    T0]                 protected nesting:  ok  |
> [    0.936784][    T0]
> --------------------------------------------------------------------------
> [    0.937936][    T0]   | wait context tests |
> [    0.938516][    T0]
> --------------------------------------------------------------------------
> [    0.939661][    T0]                                  | rcu  | raw  |
> spin |mutex |
> [    0.940646][    T0]
> --------------------------------------------------------------------------
> [    0.941798][    T0]                in hardirq context:  ok  |  ok  |
> ok  |  ok  |
> [    0.944946][    T0] in hardirq context (not threaded):  ok  |  ok  |
> ok  |  ok  |
> [    0.948072][    T0]                in softirq context:  ok  |  ok  |
> ok  |  ok  |
> [    0.951206][    T0]                    in RCU context:  ok  |  ok  |
> ok  |  ok  |
> [    0.954345][    T0]                 in RCU-bh context:  ok  |  ok  |
> ok  |  ok  |
> [    0.957477][    T0]              in RCU-sched context:  ok  |  ok  |
> ok  |  ok  |
> [    0.960612][    T0]           in RAW_SPINLOCK context:  ok  |  ok  |
> ok  |  ok  |
> [    0.963927][    T0]               in SPINLOCK context:  ok  |  ok  |
> ok  |  ok  |
> [    0.967252][    T0]                  in MUTEX context:  ok  |  ok  |
> ok  |  ok  |
> [    0.970571][    T0]
> --------------------------------------------------------------------------
> [    0.971702][    T0]   | local_lock tests |
> [    0.972422][    T0]   ---------------------
> [    0.972965][    T0]           local_lock inversion  2:  ok  |
> [    0.974319][    T0]           local_lock inversion 3A:  ok  |
> [    0.975708][    T0]           local_lock inversion 3B:  ok  |
> [    0.977106][    T0]       hardirq_unsafe_softirq_safe:  ok  |
> [    0.978595][    T0]
> --------------------------------------------------------------------------
> [    0.979723][    T0]   | lockdep_set_subclass() name test|
> [    0.980424][    T0]   -----------------------------------
> [    0.981123][    T0]     compare name before and after:  ok  |
> [    0.982423][    T0]
> -----------------------------------------------------------------
> [    0.983434][    T0] BUG:   2 unexpected failures (out of 395) -
> debugging disabled! |
> [    0.984441][    T0]
> -----------------------------------------------------------------
>
>
> Is this a known issue?

I just ran into these as well.  Looks like there's some discussion over 
here <https://lore.kernel.org/all/Zw19sMtnKdyOVQoh@boqun-archlinux/>, 
I'm trying to proposed fixes locally...

>
> Thanks,
>
> Bart.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Unexpected lockdep selftest failures
  2024-11-22 20:18 Unexpected lockdep selftest failures Bart Van Assche
  2024-11-24 21:33 ` Palmer Dabbelt
@ 2024-11-26 22:23 ` Boqun Feng
  2024-11-27  7:17   ` Thomas Hellström
  1 sibling, 1 reply; 4+ messages in thread
From: Boqun Feng @ 2024-11-26 22:23 UTC (permalink / raw)
  To: Bart Van Assche
  Cc: Peter Zijlstra, Ingo Molnar, Will Deacon, Waiman Long,
	linux-kernel, Thomas Hellström

Hi,

On Fri, Nov 22, 2024 at 12:18:40PM -0800, Bart Van Assche wrote:
> Hi,
> 
> With the for-next branch of this tree: git://git.kernel.dk/linux-block
> (commit 12ab2c13ca77 ("Merge branch 'for-6.13/block' into for-next")) I
> see the following:
> 
> 
> [    0.887603][    T0]
> --------------------------------------------------------------------------
> [    0.888763][    T0]   | Wound/wait tests |
> [    0.889310][    T0]   ---------------------
> [    0.889867][    T0]                   ww api failures:  ok  |FAILED| ok
> |
> [    0.892597][    T0]                ww contexts mixing:  ok  |  ok  |
> [    0.894638][    T0]              finishing ww context:  ok  |  ok  | ok
> |  ok  |
> [    0.898020][    T0]                locking mismatches:  ok  |  ok  | ok
> |
> [    0.900689][    T0]                  EDEADLK handling:  ok  |  ok  | ok
> |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |
> [    0.908172][    T0]            spinlock nest unlocked:  ok  |
> [    0.909484][    T0]                spinlock nest test:  ok  |
> [    0.910902][    T0] -----------------------------------------------------
> [    0.911824][    T0]                                  |block | try
> |context|
> [    0.912970][    T0] -----------------------------------------------------
> [    0.913890][    T0]                           context:  ok  |  ok  | ok
> |
> [    0.916613][    T0]                               try:  ok  |  ok  | ok
> |
> [    0.919235][    T0]                             block:  ok  |  ok  | ok
> |
> [    0.921852][    T0]                          spinlock:  ok  |  ok
> |FAILED|
> [    0.924666][    T0]
> --------------------------------------------------------------------------
> [    0.925852][    T0]   | queued read lock tests |
> [    0.926506][    T0]   ---------------------------
> [    0.927132][    T0]       hardirq read-lock/lock-read:  ok  |
> [    0.928496][    T0]       hardirq lock-read/read-lock:  ok  |
> [    0.929860][    T0]                 hardirq inversion:  ok  |
> [    0.931269][    T0]   --------------------
> [    0.931827][    T0]   | fs_reclaim tests |
> [    0.932383][    T0]   --------------------
> [    0.932932][    T0]                   correct nesting:  ok  |
> [    0.934252][    T0]                     wrong nesting:  ok  |
> [    0.935518][    T0]                 protected nesting:  ok  |
> [    0.936784][    T0]
> --------------------------------------------------------------------------
> [    0.937936][    T0]   | wait context tests |
> [    0.938516][    T0]
> --------------------------------------------------------------------------
> [    0.939661][    T0]                                  | rcu  | raw  | spin
> |mutex |
> [    0.940646][    T0]
> --------------------------------------------------------------------------
> [    0.941798][    T0]                in hardirq context:  ok  |  ok  | ok
> |  ok  |
> [    0.944946][    T0] in hardirq context (not threaded):  ok  |  ok  | ok
> |  ok  |
> [    0.948072][    T0]                in softirq context:  ok  |  ok  | ok
> |  ok  |
> [    0.951206][    T0]                    in RCU context:  ok  |  ok  | ok
> |  ok  |
> [    0.954345][    T0]                 in RCU-bh context:  ok  |  ok  | ok
> |  ok  |
> [    0.957477][    T0]              in RCU-sched context:  ok  |  ok  | ok
> |  ok  |
> [    0.960612][    T0]           in RAW_SPINLOCK context:  ok  |  ok  | ok
> |  ok  |
> [    0.963927][    T0]               in SPINLOCK context:  ok  |  ok  | ok
> |  ok  |
> [    0.967252][    T0]                  in MUTEX context:  ok  |  ok  | ok
> |  ok  |
> [    0.970571][    T0]
> --------------------------------------------------------------------------
> [    0.971702][    T0]   | local_lock tests |
> [    0.972422][    T0]   ---------------------
> [    0.972965][    T0]           local_lock inversion  2:  ok  |
> [    0.974319][    T0]           local_lock inversion 3A:  ok  |
> [    0.975708][    T0]           local_lock inversion 3B:  ok  |
> [    0.977106][    T0]       hardirq_unsafe_softirq_safe:  ok  |
> [    0.978595][    T0]
> --------------------------------------------------------------------------
> [    0.979723][    T0]   | lockdep_set_subclass() name test|
> [    0.980424][    T0]   -----------------------------------
> [    0.981123][    T0]     compare name before and after:  ok  |
> [    0.982423][    T0]
> -----------------------------------------------------------------
> [    0.983434][    T0] BUG:   2 unexpected failures (out of 395) - debugging
> disabled! |
> [    0.984441][    T0]
> -----------------------------------------------------------------
> 
> 
> Is this a known issue?
> 

Yes, these were reported at:

	https://lore.kernel.org/lkml/Zw19sMtnKdyOVQoh@boqun-archlinux/

and Thomas (Cced) send an updated version:

	https://lore.kernel.org/lkml/20241017151007.92215-1-thomas.hellstrom@linux.intel.com/

, which wasn't picked up. :(

Thomas, could you send a fix ontop? I'm happy to review and test it.
Thanks!

Regards,
Boqun

> Thanks,
> 
> Bart.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Unexpected lockdep selftest failures
  2024-11-26 22:23 ` Boqun Feng
@ 2024-11-27  7:17   ` Thomas Hellström
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas Hellström @ 2024-11-27  7:17 UTC (permalink / raw)
  To: Boqun Feng, Bart Van Assche
  Cc: Peter Zijlstra, Ingo Molnar, Will Deacon, Waiman Long,
	linux-kernel

On Tue, 2024-11-26 at 14:23 -0800, Boqun Feng wrote:
> Hi,
> 
> On Fri, Nov 22, 2024 at 12:18:40PM -0800, Bart Van Assche wrote:
> > Hi,
> > 
> > With the for-next branch of this tree: git://git.kernel.dk/linux-
> > block
> > (commit 12ab2c13ca77 ("Merge branch 'for-6.13/block' into for-
> > next")) I
> > see the following:
> > 
> > 
> > [    0.887603][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.888763][    T0]   | Wound/wait tests |
> > [    0.889310][    T0]   ---------------------
> > [    0.889867][    T0]                   ww api failures:  ok 
> > |FAILED| ok
> > > 
> > [    0.892597][    T0]                ww contexts mixing:  ok  | 
> > ok  |
> > [    0.894638][    T0]              finishing ww context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.898020][    T0]                locking mismatches:  ok  | 
> > ok  | ok
> > > 
> > [    0.900689][    T0]                  EDEADLK handling:  ok  | 
> > ok  | ok
> > >  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |  ok  |
> > [    0.908172][    T0]            spinlock nest unlocked:  ok  |
> > [    0.909484][    T0]                spinlock nest test:  ok  |
> > [    0.910902][    T0] --------------------------------------------
> > ---------
> > [    0.911824][    T0]                                  |block |
> > try
> > > context|
> > [    0.912970][    T0] --------------------------------------------
> > ---------
> > [    0.913890][    T0]                           context:  ok  | 
> > ok  | ok
> > > 
> > [    0.916613][    T0]                               try:  ok  | 
> > ok  | ok
> > > 
> > [    0.919235][    T0]                             block:  ok  | 
> > ok  | ok
> > > 
> > [    0.921852][    T0]                          spinlock:  ok  | 
> > ok
> > > FAILED|
> > [    0.924666][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.925852][    T0]   | queued read lock tests |
> > [    0.926506][    T0]   ---------------------------
> > [    0.927132][    T0]       hardirq read-lock/lock-read:  ok  |
> > [    0.928496][    T0]       hardirq lock-read/read-lock:  ok  |
> > [    0.929860][    T0]                 hardirq inversion:  ok  |
> > [    0.931269][    T0]   --------------------
> > [    0.931827][    T0]   | fs_reclaim tests |
> > [    0.932383][    T0]   --------------------
> > [    0.932932][    T0]                   correct nesting:  ok  |
> > [    0.934252][    T0]                     wrong nesting:  ok  |
> > [    0.935518][    T0]                 protected nesting:  ok  |
> > [    0.936784][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.937936][    T0]   | wait context tests |
> > [    0.938516][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.939661][    T0]                                  | rcu  |
> > raw  | spin
> > > mutex |
> > [    0.940646][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.941798][    T0]                in hardirq context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.944946][    T0] in hardirq context (not threaded):  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.948072][    T0]                in softirq context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.951206][    T0]                    in RCU context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.954345][    T0]                 in RCU-bh context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.957477][    T0]              in RCU-sched context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.960612][    T0]           in RAW_SPINLOCK context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.963927][    T0]               in SPINLOCK context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.967252][    T0]                  in MUTEX context:  ok  | 
> > ok  | ok
> > >  ok  |
> > [    0.970571][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.971702][    T0]   | local_lock tests |
> > [    0.972422][    T0]   ---------------------
> > [    0.972965][    T0]           local_lock inversion  2:  ok  |
> > [    0.974319][    T0]           local_lock inversion 3A:  ok  |
> > [    0.975708][    T0]           local_lock inversion 3B:  ok  |
> > [    0.977106][    T0]       hardirq_unsafe_softirq_safe:  ok  |
> > [    0.978595][    T0]
> > -------------------------------------------------------------------
> > -------
> > [    0.979723][    T0]   | lockdep_set_subclass() name test|
> > [    0.980424][    T0]   -----------------------------------
> > [    0.981123][    T0]     compare name before and after:  ok  |
> > [    0.982423][    T0]
> > -----------------------------------------------------------------
> > [    0.983434][    T0] BUG:   2 unexpected failures (out of 395) -
> > debugging
> > disabled! |
> > [    0.984441][    T0]
> > -----------------------------------------------------------------
> > 
> > 
> > Is this a known issue?
> > 
> 
> Yes, these were reported at:
> 
> 	
> https://lore.kernel.org/lkml/Zw19sMtnKdyOVQoh@boqun-archlinux/
> 
> and Thomas (Cced) send an updated version:
> 
> 	
> https://lore.kernel.org/lkml/20241017151007.92215-1-thomas.hellstrom@
> linux.intel.com/
> 
> , which wasn't picked up. :(
> 
> Thomas, could you send a fix ontop? I'm happy to review and test it.
> Thanks!
> 
> Regards,
> Boqun

Yes, I'll do that.

For some reason the incorrect version was also queued for stable
backport. I replied to those backport patches and asked them not to be
backported, but has not seen any replies yet.

Thanks,
Thomas



> 
> > Thanks,
> > 
> > Bart.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-11-27  7:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-22 20:18 Unexpected lockdep selftest failures Bart Van Assche
2024-11-24 21:33 ` Palmer Dabbelt
2024-11-26 22:23 ` Boqun Feng
2024-11-27  7:17   ` Thomas Hellström

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox