Files
linux-stable-mirror/include/linux
Sebastian Andrzej SiewiorandGreg Kroah-Hartman 4210ca861f lockdep: Don't disable interrupts on RT in disable_irq_nosync_lockdep.*()
[ Upstream commit 87886b32d6 ]

disable_irq_nosync_lockdep() disables interrupts with lockdep enabled to
avoid false positive reports by lockdep that a certain lock has not been
acquired with disabled interrupts. The user of this macros expects that
a lock can be acquried without disabling interrupts because the IRQ line
triggering the interrupt is disabled.

This triggers a warning on PREEMPT_RT because after
disable_irq_nosync_lockdep.*() the following spinlock_t now is acquired
with disabled interrupts.

On PREEMPT_RT there is no difference between spin_lock() and
spin_lock_irq() so avoiding disabling interrupts in this case works for
the two remaining callers as of today.

Don't disable interrupts on PREEMPT_RT in disable_irq_nosync_lockdep.*().

Closes: https://lore.kernel.org/760e34f9-6034-40e0-82a5-ee9becd24438@roeck-us.net
Fixes: e8106b941c ("[PATCH] lockdep: core, add enable/disable_irq_irqsave/irqrestore() APIs")
Reported-by: Guenter Roeck <linux@roeck-us.net>
Suggested-by: "Steven Rostedt (Google)" <rostedt@goodmis.org>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20250212103619.2560503-2-bigeasy@linutronix.de
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-04-10 14:33:31 +02:00
..
2024-06-12 11:03:08 +02:00
2025-01-17 13:34:43 +01:00
2024-07-05 09:31:59 +02:00
2024-12-14 19:53:51 +01:00
2024-10-17 15:21:32 +02:00
2024-03-26 18:21:02 -04:00
2024-12-14 19:54:37 +01:00
2024-12-27 13:52:52 +01:00
2025-02-21 13:49:55 +01:00
2024-06-12 11:03:21 +02:00
2025-03-28 21:59:01 +01:00
2025-02-01 18:30:05 +01:00
2025-03-07 16:56:37 +01:00
2024-10-17 15:21:12 +02:00