netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] Introduce auxiliary bus IRQs sysfs
@ 2024-05-03  4:31 Shay Drory
  2024-05-03  4:31 ` [PATCH 1/2] driver core: auxiliary bus: show auxiliary device IRQs Shay Drory
  2024-05-03  4:31 ` [PATCH 2/2] net/mlx5: Expose SFs IRQs Shay Drory
  0 siblings, 2 replies; 9+ messages in thread
From: Shay Drory @ 2024-05-03  4:31 UTC (permalink / raw)
  To: netdev, pabeni, davem, kuba, edumazet, gregkh, david.m.ertman
  Cc: rafael, ira.weiny, linux-rdma, leon, tariqt, Shay Drory

Today, PCI PFs and VFs, which are anchored on the PCI bus, display their
IRQ information in the <pci_device>/msi_irqs/<irq_num> sysfs files.
PCI subfunctions (SFs) are similar to PFs and VFs and these SFs are
anchored on the auxiliary bus. However, these PCI SFs lack such IRQ
information on the auxiliary bus, leaving users without visibility into
which IRQs are used by the SFs. This absence makes it impossible to debug
situations and to understand the source of interrupts/SFs for performance
tuning and debug.

Additionally, the SFs are multifunctional devices supporting RDMA,
network devices, clocks, and more, similar to their peer PCI PFs and
VFs. Therefore, it is desirable to have SFs' IRQ information available
at the bus/device level.

To overcome the above limitations, this short series extends the auxiliary
bus to display IRQ information in sysfs, similar to that of PFs and VFs.

It adds an 'irqs' directory under the auxiliary device and includes an
<irq_num> sysfs file within it. Sometimes, the PCI SF auxiliary devices
share the IRQ with other SFs, a detail that is also not available to the
users. Consequently, this <irq_num> file indicates whether the IRQ is
'exclusive' or 'shared'.

For example:
$ ls /sys/bus/auxiliary/devices/mlx5_core.sf.1/irqs/
50  51  52  53  54  55  56  57  58
$ cat /sys/bus/auxiliary/devices/mlx5_core.sf.1/irqs/52
exclusive

Patch summary:
==============
patch-1 adds auxiliary bus to support irqs used by auxiliary device
patch-2 mlx5 driver using exposing irqs for PCI SF devices via auxiliary
        bus

Shay Drory (2):
  driver core: auxiliary bus: show auxiliary device IRQs
  net/mlx5: Expose SFs IRQs

 Documentation/ABI/testing/sysfs-bus-auxiliary |  14 ++
 drivers/base/auxiliary.c                      | 170 +++++++++++++++++-
 drivers/net/ethernet/mellanox/mlx5/core/eq.c  |   6 +-
 .../mellanox/mlx5/core/irq_affinity.c         |  15 +-
 .../ethernet/mellanox/mlx5/core/mlx5_core.h   |   6 +
 .../ethernet/mellanox/mlx5/core/mlx5_irq.h    |  12 +-
 .../net/ethernet/mellanox/mlx5/core/pci_irq.c |  12 +-
 .../ethernet/mellanox/mlx5/core/sf/dev/dev.c  |   2 +-
 include/linux/auxiliary_bus.h                 |  15 +-
 9 files changed, 237 insertions(+), 15 deletions(-)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-auxiliary

-- 
2.38.1


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

end of thread, other threads:[~2024-05-05  8:43 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-03  4:31 [PATCH 0/2] Introduce auxiliary bus IRQs sysfs Shay Drory
2024-05-03  4:31 ` [PATCH 1/2] driver core: auxiliary bus: show auxiliary device IRQs Shay Drory
2024-05-03  5:10   ` Greg KH
2024-05-03  6:18     ` Shay Drori
2024-05-03 17:14   ` kernel test robot
2024-05-05  8:43     ` Zhu Yanjun
2024-05-04 17:50   ` Simon Horman
2024-05-05  5:16     ` Shay Drori
2024-05-03  4:31 ` [PATCH 2/2] net/mlx5: Expose SFs IRQs Shay Drory

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