Skip to content

msi: extend msi_irqs sysfs entries to platform devices

Barry Song linux-pci lkml 2 versions – Applied

Status from this message: The following commit has been merged into the irq/core branch of tip:

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest2 patches 1 replyApplied
  2. v22 patches 2 repliesSuperseded

Patches in v3 Applied

#Subject and filesSizeRepliesApplied
1/2genirq/msi: Extract common sysfs populate entries to MSI core from PCIdrivers/pci/msi.c include/linux/msi.h kernel/irq/msi.c+147 -1150 replies
2/2platform-msi: Add ABI to show msi_irqs of platform devicesDocumentation/ABI/testing/sysfs-bus-platform drivers/base/platform-msi.c+24 -00 replies

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchGreg Kroah-HartmanBjorn HelgaasMarc Zyngier
SeriesA-b
1/2A-b A-b
2/2A-b A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v3 thread

Cover letter [PATCH v3 0/2] msi: extend msi_irqs sysfs entries to platform devices

From: Barry Song <[email protected]>

-v3:
added Acked-by of Greg Kroah-Hartman and Bjorn Helgaas, thanks! refined commit log with respect to Bjorn's comments

Hi Thomas & Marc,
Would you please handle this series? Thanks!

-v2:
extract common code for msi_irqs sysfs populate/destory from PCI to MSI core, platform_device can directly reuse common code;
https://lore.kernel.org/lkml/[email protected]/

-v1:
https://lore.kernel.org/lkml/[email protected]/

Just like pci devices have msi_irqs which can be used by userspace irq affinity tools or applications to bind irqs, platform devices also widely support msi irqs.
For platform devices, for example ARM SMMU, userspaces also care about its msi irqs as applications can know the mapping between devices and irqs and then make smarter decision on handling irq affinity. For example, for SVA mode, it is better to pin io page fault to the numa node applications are running on. Otherwise, io page fault will get a remote page from the node iopf happens rather than from the node applications are running on.

The first patch extracts the sysfs populate/destory code from PCI to MSI core. The 2nd patch lets platform-msi export msi_irqs entry so that userspace can know the mapping between devices and irqs for platform devices.

Barry Song (2):
genirq/msi: Extract common sysfs populate entries to MSI core from PCI
platform-msi: Add ABI to show msi_irqs of platform devices

 Documentation/ABI/testing/sysfs-bus-platform |  14 +++
 drivers/base/platform-msi.c                  |  10 ++
 drivers/pci/msi.c                            | 124 ++-----------------------
 include/linux/msi.h                          |   4 +
 kernel/irq/msi.c                             | 134 +++++++++++++++++++++++++++
 5 files changed, 171 insertions(+), 115 deletions(-)
Signature · 1 line
1.8.3.1