[PATCH] PCI: Add quirk to mask ACSViol on XHCI on iMac20,1 And iMac20,2
From: Atharva Tiwari
Date: Sun Nov 15 2026 - 20:08:49 EST
On iMac20,1 and iMac20,2 the Thunderbolt xHCI (8086:15ec) triggers an ACS
Violation on its upstream port whenever it is runtime-resumed from D3hot,
e.g. on suspend and shutdown:
[ 141.535310] pcieport 0000:00:1c.4: AER: Uncorrectable (Non-Fatal) Error message received from 0000:08:02.0
[ 141.535325] pcieport 0000:08:02.0: PCIe Bus Error: severity=Uncorrectable (Non-Fatal)
[ 141.535325] pcieport 0000:08:02.0: device [8086:15ea] error status/mask=00200000/00000000
[ 141.535327] pcieport 0000:08:02.0: [21] ACSViol | Receiver | Transaction Layer (First)
[ 141.535328] pcieport 0000:08:02.0: AER: TLP Header: 0x34000000 0x00000010 0x00000000 0x00000000
[ 141.551637] xhci_hcd 0000:0a:00.0: AER: can't recover (no error_detected callback)
[ 141.551655] pcieport 0000:08:02.0: AER: device recovery failed
The violation is raised inside the 10 ms D3hot->D0 recovery window: the
port's AER status is still clean right after the PM_CTRL write
and set once the delay has elapsed,
before any config space has been restored.
The kernel cannot run anything in that window.
The ACPI _PS0 and _PS3 methods were also checked and have no effect on it.
This is most likely a hardware defect: the port correctly drops the
message, and the same controller on MacBookPro16,1 is not affected. The
error is unrecoverable noise, so mask ACSViol on the upstream port on these
models. ACS stays enabled.
Signed-off-by: Atharva Tiwari <atharvatiwarilinuxdev@xxxxxxxxx>
---
arch/x86/pci/fixup.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/arch/x86/pci/fixup.c b/arch/x86/pci/fixup.c
index 795d81c7a..b7c0de6c2 100644
--- a/arch/x86/pci/fixup.c
+++ b/arch/x86/pci/fixup.c
@@ -1094,6 +1094,26 @@ static void asus_disable_nvme_d3cold(struct pci_dev *pdev)
}
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x9a09, asus_disable_nvme_d3cold);
+#ifdef CONFIG_PCIEAER
+/*
+ * On iMac20,1 and iMac20,2 the XHCI controller gives ACSViolations
+ * When switching from D3Hot/D3cold to D0, and it happens because of
+ * the D0 write, so we mask ACSViol at boot on these devices.
+ */
+static void titan_ridge_xhci_mask_acsv(struct pci_dev *pdev)
+{
+ struct pci_dev *up = pci_upstream_bridge(pdev);
+
+ if (!dmi_match(DMI_PRODUCT_NAME, "iMac20,1") &&
+ !dmi_match(DMI_PRODUCT_NAME, "iMac20,2"))
+ return;
+ if (up && up->aer_cap)
+ pci_clear_and_set_config_dword(up, up->aer_cap + PCI_ERR_UNCOR_MASK,
+ 0, PCI_ERR_UNC_ACSV);
+}
+DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x15ec, titan_ridge_xhci_mask_acsv);
+#endif /* CONFIG_PCIEAER */
+
#ifdef CONFIG_SUSPEND
/*
* Root Ports on some AMD SoCs advertise PME_Support for D3hot and D3cold, but
--
2.55.0