]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
cxl/core: Fix cxl_dport debugfs EINJ entries
authorCheatham, Benjamin <benjamin.cheatham@amd.com>
Fri, 9 Jan 2026 13:57:38 +0000 (07:57 -0600)
committerDave Jiang <dave.jiang@intel.com>
Thu, 22 Jan 2026 23:58:13 +0000 (16:58 -0700)
commit4ed7952b9e87cf731ebc8251874416e60eb15230
treeeb100faec6d5b78feb751b0cd782003e2766ef0e
parent99698e70148fbce4410799570adac8456204fa37
cxl/core: Fix cxl_dport debugfs EINJ entries

Protocol error injection is only valid for CXL 2.0+ root ports and CXL
1.1 memory-mapped downstream ports as per the ACPI v6.5 spec (Table
8-31). The core code currently creates an 'einj_inject' file in CXL debugfs
for all CXL 1.1 downstream ports and all PCI CXL 2.0+ downstream ports.
This results in debugfs EINJ files that won't work due to platform/spec
restrictions.

Fix by limiting 'einj_inject' file creation to only CXL 1.1 dports and
CXL 2.0+ root ports. Update the comment above the check to more accurately
represent the requirements expected by the EINJ module and ACPI spec.

Fixes: 8039804cfa73 ("cxl/core: Add CXL EINJ debugfs files")
Signed-off-by: Ben Cheatham <Benjamin.Cheatham@amd.com>
Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>
Reviewed-by: Alison Schofield <alison.schofield@intel.com>
Reviewed-by: Dave Jiang <dave.jiang@intel.com>
Link: https://patch.msgid.link/6e9fb657-8264-4028-92e2-5428e2695bf1@amd.com
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
drivers/cxl/core/port.c