[PATCH v3 0/6] PCIe Flit Logging Ext Capability Support
From: Yazen Ghannam
Date: Fri Dec 04 2026 - 13:16:39 EST
Hi all,
This set adds support for the PCIe Flit Logging Extended Capability,
including Capability Version 2h from PCIe r7.1.
I wanted to focus on the feature enablement and handling part. So I left
out the ratelimiting and sysfs changes from the previous revision.
Also, I thought it'd be good to include the 'Version 2h' capability
features along with 'Version 1h'. The goal was to avoid a bunch of
rework by keeping them together.
Hardware is not yet available for the 'Version 2h' capability. So these
patches are based on interpreting the spec and testing with QEMU models.
Thanks,
Yazen
Tool use: an LLM coding assistant drafted code, comments and commit
messages under the author's direction, checked the patches against the
spec, and wrote the QEMU model and tests. The author reviewed, edited
and tested all patches.
v2->v3:
* Drop the AER sysfs fixes (v2 1-4), now in pci/aer.
https://lore.kernel.org/r/20261110215614.3931232-1-yazen.ghannam@xxxxxxx
* Defer the ratelimit accessors, trace event, ratelimiting and sysfs
(v2 5, 8-10) and Sashiko's v2 10/10 findings to a later set.
* New patch 2. (Ilpo)
* Patch 3: address Ilpo's comments.
https://lore.kernel.org/r/3d907699-9f79-0740-2b84-7990f1e9eac1@xxxxxxxxxxxxxxx
* Patch 3: disable the counter before free_irq(). (Sashiko)
https://lore.kernel.org/r/20260918151242.B1A821F000FF@xxxxxxxxxxxxxxx
* Patch 3: treat Flit Logging like the other port services, copy it to
VMD, depend on PCIEAER.
* Patch 3: restore under lock.
* New patches 4-6.
* Drop the Assisted-by trailers. See the tool use note.
v2: https://lore.kernel.org/r/20260918145619.3016889-1-yazen.ghannam@xxxxxxx
v1->v2:
* Address Sashiko bot feedback.
* Fix sysfs issues found during development.
* Add sysfs controls for Flit logging parameters.
v1: https://lore.kernel.org/r/20260714183950.1620016-1-yazen.ghannam@xxxxxxx
Yazen Ghannam (6):
PCI/portdrv: Group PCI Exp Cap services into a single mask
PCI: Add pci_clear_and_set_config_word()
PCI/FLIT: Add support for Flit Logging Extended Capability
PCI/FLIT: Add support for the Extended Flit Error Counter
PCI/FLIT: Signal Flit Error Counter events with ERR_COR
PCI/FLIT: Manage Flit Logging on Endpoint Upstream Ports
drivers/acpi/pci_root.c | 15 +-
drivers/pci/access.c | 11 +
drivers/pci/controller/vmd.c | 1 +
drivers/pci/pci.c | 2 +
drivers/pci/pci.h | 22 ++
drivers/pci/pcie/Kconfig | 9 +
drivers/pci/pcie/Makefile | 1 +
drivers/pci/pcie/aer.c | 22 ++
drivers/pci/pcie/flit.c | 669 ++++++++++++++++++++++++++++++++++
drivers/pci/pcie/portdrv.c | 20 +-
drivers/pci/pcie/portdrv.h | 16 +-
drivers/pci/probe.c | 3 +
include/linux/acpi.h | 1 +
include/linux/pci.h | 6 +
include/uapi/linux/pci_regs.h | 37 +-
15 files changed, 822 insertions(+), 13 deletions(-)
create mode 100644 drivers/pci/pcie/flit.c
base-commit: dd1f6bb875acef47745790b92fe321e15df05139
--
2.55.0