mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] pinctrl: ocelot: fix the GPIO irqchip context handling
@ 2026-11-09 13:50 Jens Emil Schulz Østergaard
  2026-11-09 13:50 ` [PATCH 1/2] pinctrl: ocelot: use a raw spinlock for the GPIO regmap Jens Emil Schulz Østergaard
  2026-11-09 13:50 ` [PATCH 2/2] pinctrl: ocelot: do not use the chained irqchip behind a sleeping bus Jens Emil Schulz Østergaard
  0 siblings, 2 replies; 3+ messages in thread
From: Jens Emil Schulz Østergaard @ 2026-11-09 13:50 UTC (permalink / raw)
  To: Linus Walleij, Sebastian Andrzej Siewior, Clark Williams,
	Steven Rostedt, Horatiu Vultur, Colin Foster, Andy Shevchenko,
	Lee Jones, Vladimir Oltean
  Cc: Alexandre Belloni, linux-gpio, linux-kernel, linux-rt-devel,
	Jens Emil Schulz Østergaard

Two fixes for the GPIO irqchip of pinctrl-ocelot, where the irq_chip
callbacks take locks that are not allowed in the calling context.

The first makes the GPIO regmap use a raw spinlock. The callbacks run
with the raw spinlock irq_desc::lock held, where the spinlock_t of the
MMIO regmap is not allowed on PREEMPT_RT and is reported by
CONFIG_PROVE_RAW_LOCK_NESTING.

The second covers the regmap on a bus that can sleep, as for VSC7512
and lan9645x attached over SPI: the gpiochip is marked as sleeping and
the chained irqchip, whose callbacks run in atomic context, is no longer
registered.

The two patches are independent of each other. Both issues were
reproduced and the fixes tested on a lan9668 board (pcb8385), the
second with a lan9645x attached over SPI.

Signed-off-by: Jens Emil Schulz Østergaard <jensemil.schulzostergaard@microchip.com>
---
Jens Emil Schulz Østergaard (2):
      pinctrl: ocelot: use a raw spinlock for the GPIO regmap
      pinctrl: ocelot: do not use the chained irqchip behind a sleeping bus

 drivers/pinctrl/pinctrl-ocelot.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
base-commit: ff00e5c03e7efe88f7a50a8673b14e8f0d4b45bb
change-id: 20261109-ocelot-pinctrl-irqchip-fixes-74ef6d92e6f8

Best regards,
-- 
Jens Emil Schulz Østergaard <jensemil.schulzostergaard@microchip.com>


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

end of thread, other threads:[~2026-11-09 13:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-09 13:50 [PATCH 0/2] pinctrl: ocelot: fix the GPIO irqchip context handling Jens Emil Schulz Østergaard
2026-11-09 13:50 ` [PATCH 1/2] pinctrl: ocelot: use a raw spinlock for the GPIO regmap Jens Emil Schulz Østergaard
2026-11-09 13:50 ` [PATCH 2/2] pinctrl: ocelot: do not use the chained irqchip behind a sleeping bus Jens Emil Schulz Østergaard

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

all inboxes | Powered by JetHome®