linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/12] irqchip: MSI cleanup and conversion to MSI parent domain
@ 2025-06-26 14:48 Nam Cao
  2025-06-26 14:48 ` [PATCH 01/12] irqdomain: Add device pointer to irq_domain_info and msi_domain_info Nam Cao
                   ` (12 more replies)
  0 siblings, 13 replies; 18+ messages in thread
From: Nam Cao @ 2025-06-26 14:48 UTC (permalink / raw)
  To: Marc Zyngier, Thomas Gleixner, Antoine Tenart, Andrew Lunn,
	Gregory Clement, Sebastian Hesselbarth, Shawn Guo, Sascha Hauer,
	Pengutronix Kernel Team, Fabio Estevam, Huacai Chen, Jiaxun Yang,
	Anup Patel, Paul Walmsley, Palmer Dabbelt, Albert Ou,
	Alexandre Ghiti, linux-kernel, linux-arm-kernel, imx, linux-mips,
	linux-riscv
  Cc: Nam Cao

The initial implementation of PCI/MSI interrupt domains in the hierarchical
interrupt domain model used a shortcut by providing a global PCI/MSI
domain.

This works because the PCI/MSI[X] hardware is standardized and uniform, but
it violates the basic design principle of hierarchical interrupt domains:
Each hardware block involved in the interrupt delivery chain should have a
separate interrupt domain.

For PCI/MSI[X], the interrupt controller is per PCI device and not a global
made-up entity.

Unsurprisingly, the shortcut turned out to have downsides as it does not
allow dynamic allocation of interrupt vectors after initialization and it
prevents supporting IMS on PCI. For further details, see:

https://lore.kernel.org/lkml/20221111120501.026511281@linutronix.de/

The solution is implementing per device MSI domains, this means the
entities which provide global PCI/MSI domain so far have to implement MSI
parent domain functionality instead.

Aside from that, the creation of MSI parent domains has been simplified by
new helper functions, which are not yet used by all drivers.

This series addresses this by:

   - Converting the remaining global PCI/MSI domain providers to MSI parent
     domains

   - Converting the existing MSI parent domain implementations to the
     simplified setup function

 drivers/irqchip/Kconfig                    |   3 +
 drivers/irqchip/irq-alpine-msi.c           | 155 ++++++++-------------
 drivers/irqchip/irq-armada-370-xp.c        |  48 ++++---
 drivers/irqchip/irq-bcm2712-mip.c          |  20 +--
 drivers/irqchip/irq-imx-mu-msi.c           |  14 +-
 drivers/irqchip/irq-loongson-pch-msi.c     |  25 ++--
 drivers/irqchip/irq-ls-scfg-msi.c          |  49 +++----
 drivers/irqchip/irq-riscv-imsic-platform.c |  12 +-
 drivers/irqchip/irq-sg2042-msi.c           |  20 ++-
 include/linux/irqdomain.h                  |   2 +
 include/linux/msi.h                        |   2 +
 kernel/irq/irqdomain.c                     |   1 +
 kernel/irq/msi.c                           |   3 +-
 13 files changed, 155 insertions(+), 199 deletions(-)

-- 
2.39.5


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

end of thread, other threads:[~2025-08-11 12:52 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-26 14:48 [PATCH 00/12] irqchip: MSI cleanup and conversion to MSI parent domain Nam Cao
2025-06-26 14:48 ` [PATCH 01/12] irqdomain: Add device pointer to irq_domain_info and msi_domain_info Nam Cao
2025-06-26 14:48 ` [PATCH 02/12] irqchip/bcm2712-mip: Switch to msi_create_parent_irq_domain() Nam Cao
2025-06-26 16:12   ` Nam Cao
2025-06-26 14:49 ` [PATCH 03/12] irqchip/riscv-imsic: Convert to msi_create_parent_irq_domain() helper Nam Cao
2025-06-26 14:49 ` [PATCH 04/12] irqchip/imx-mu-msi: " Nam Cao
2025-06-26 16:08   ` Frank Li
2025-06-26 14:49 ` [PATCH 05/12] irqchip/loongson-pch-msi.c: Switch to msi_create_parent_irq_domain() Nam Cao
2025-06-26 14:49 ` [PATCH 06/12] irqchip/sg2042-msi: " Nam Cao
2025-06-28  2:01   ` Chen Wang
2025-06-26 14:49 ` [PATCH 07/12] irqchip/alpine-msi: Clean up whitespace style Nam Cao
2025-06-26 14:49 ` [PATCH 08/12] irqchip/alpine-msi: Convert to lock guards Nam Cao
2025-06-26 14:49 ` [PATCH 09/12] irqchip/alpine-msi: Convert to __free Nam Cao
2025-06-26 14:49 ` [PATCH 10/12] irqchip/alpine-msi: Switch to msi_create_parent_irq_domain() Nam Cao
2025-06-26 14:49 ` [PATCH 11/12] irqchip/armada-370-xp: " Nam Cao
2025-06-26 14:49 ` [PATCH 12/12] irqchip/ls-scfg-msi: Switch to use msi_create_parent_irq_domain() Nam Cao
2025-08-10 21:12 ` [PATCH 00/12] irqchip: MSI cleanup and conversion to MSI parent domain patchwork-bot+linux-riscv
2025-08-11 12:52   ` Thomas Gleixner

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).