Skip to content

Commit 8935e30

Browse files
authored
PCI: dwc: Remove MSI/MSIX capability if iMSI-RX is used as … (#408)
FROMLIST: PCI: dwc: Remove MSI/MSIX capability if iMSI-RX is used as …
2 parents c2ee216 + 46992e0 commit 8935e30

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

drivers/pci/controller/dwc/pcie-designware-host.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1106,6 +1106,16 @@ int dw_pcie_setup_rc(struct dw_pcie_rp *pp)
11061106

11071107
dw_pcie_dbi_ro_wr_dis(pci);
11081108

1109+
/*
1110+
* If iMSI-RX module is used as the MSI controller, remove MSI and
1111+
* MSI-X capabilities from PCIe Root Ports to ensure fallback to INTx
1112+
* interrupt handling.
1113+
*/
1114+
if (pp->has_msi_ctrl) {
1115+
dw_pcie_remove_capability(pci, PCI_CAP_ID_MSI);
1116+
dw_pcie_remove_capability(pci, PCI_CAP_ID_MSIX);
1117+
}
1118+
11091119
return 0;
11101120
}
11111121
EXPORT_SYMBOL_GPL(dw_pcie_setup_rc);

0 commit comments

Comments
 (0)