From b6e80702a1c32c370b2f946669fbba8abca34b9f Mon Sep 17 00:00:00 2001 From: Matt DeVillier Date: Sun, 25 Jan 2026 20:55:07 -0600 Subject: [PATCH] soc/intel: Use chipset.cb for XHCI device ops linking Move XHCI device operations linking from PCI Device ID matching to chipset.cb files for all Intel SoCs that have them, matching the approach used by Skylake. Remove corresponding DIDs from xhci.c for these SoCs; keep DID matching only for SoCs without chipset.cb files. This standardizes the approach across Intel SoCs and makes the XHCI controller configuration explicit in devicetree, and prevents the endless proliferation of DIDs in the common driver code. Change-Id: I4a0551a0fc5a233153c62d5bb7b0b2f3596a81ac Signed-off-by: Matt DeVillier Reviewed-on: https://review.coreboot.org/c/coreboot/+/90920 Tested-by: build bot (Jenkins) Reviewed-by: Jakub "Kuba" Czapiga --- src/soc/intel/alderlake/chipset.cb | 2 +- src/soc/intel/alderlake/chipset_pch_s.cb | 2 +- src/soc/intel/apollolake/chipset_apl.cb | 2 +- src/soc/intel/apollolake/chipset_glk.cb | 2 +- src/soc/intel/cannonlake/chipset.cb | 2 +- src/soc/intel/cannonlake/chipset_pch_h.cb | 2 +- src/soc/intel/common/block/xhci/xhci.c | 19 ------------------- src/soc/intel/jasperlake/chipset.cb | 2 +- src/soc/intel/meteorlake/chipset.cb | 2 +- src/soc/intel/pantherlake/chipset_ptl.cb | 2 +- src/soc/intel/pantherlake/chipset_wcl.cb | 2 +- src/soc/intel/tigerlake/chipset.cb | 2 +- src/soc/intel/tigerlake/chipset_pch_h.cb | 2 +- 13 files changed, 12 insertions(+), 31 deletions(-) diff --git a/src/soc/intel/alderlake/chipset.cb b/src/soc/intel/alderlake/chipset.cb index b942157c4d..3d2ced5f00 100644 --- a/src/soc/intel/alderlake/chipset.cb +++ b/src/soc/intel/alderlake/chipset.cb @@ -180,7 +180,7 @@ chip soc/intel/alderlake device pci 12.6 alias gspi2 off ops spi_dev_ops end device pci 12.7 alias ufs off end device pci 13.0 alias gspi3 off ops spi_dev_ops end - device pci 14.0 alias xhci off + device pci 14.0 alias xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/alderlake/chipset_pch_s.cb b/src/soc/intel/alderlake/chipset_pch_s.cb index 36ca14755d..6e4247817a 100644 --- a/src/soc/intel/alderlake/chipset_pch_s.cb +++ b/src/soc/intel/alderlake/chipset_pch_s.cb @@ -281,7 +281,7 @@ chip soc/intel/alderlake device pci 12.0 alias ish off end device pci 12.6 alias gspi2 off ops spi_dev_ops end device pci 13.0 alias gspi3 off ops spi_dev_ops end - device pci 14.0 alias xhci off + device pci 14.0 alias xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/apollolake/chipset_apl.cb b/src/soc/intel/apollolake/chipset_apl.cb index 5784265855..5abba624bf 100644 --- a/src/soc/intel/apollolake/chipset_apl.cb +++ b/src/soc/intel/apollolake/chipset_apl.cb @@ -22,7 +22,7 @@ chip soc/intel/apollolake device pci 13.3 alias pcie_rp04 off ops pcie_rp_ops end # PCIE Express Root Port 4 device pci 14.0 alias pcie_rp05 off ops pcie_rp_ops end # PCIE Express Root Port 5 device pci 14.1 alias pcie_rp06 off ops pcie_rp_ops end # PCIE Express Root Port 6 - device pci 15.0 alias xhci off end # XHCI + device pci 15.0 alias xhci off ops usb_xhci_ops end # XHCI device pci 15.1 alias xdci off end # XDCI device pci 16.0 alias i2c0 off ops i2c_dev_ops end # I2C0 device pci 16.1 alias i2c1 off ops i2c_dev_ops end # I2C1 diff --git a/src/soc/intel/apollolake/chipset_glk.cb b/src/soc/intel/apollolake/chipset_glk.cb index 2a4defe7c7..9a8732dd94 100644 --- a/src/soc/intel/apollolake/chipset_glk.cb +++ b/src/soc/intel/apollolake/chipset_glk.cb @@ -23,7 +23,7 @@ chip soc/intel/apollolake device pci 13.3 alias pcie_rp04 off ops pcie_rp_ops end # PCIE Express Root Port 4 device pci 14.0 alias pcie_rp05 off ops pcie_rp_ops end # PCIE Express Root Port 5 device pci 14.1 alias pcie_rp06 off ops pcie_rp_ops end # PCIE Express Root Port 6 - device pci 15.0 alias xhci off end # XHCI + device pci 15.0 alias xhci off ops usb_xhci_ops end # XHCI device pci 15.1 alias xdci off end # XDCI device pci 16.0 alias i2c0 off ops i2c_dev_ops end # I2C0 device pci 16.1 alias i2c1 off ops i2c_dev_ops end # I2C1 diff --git a/src/soc/intel/cannonlake/chipset.cb b/src/soc/intel/cannonlake/chipset.cb index e0f20ae8a8..5b94869d87 100644 --- a/src/soc/intel/cannonlake/chipset.cb +++ b/src/soc/intel/cannonlake/chipset.cb @@ -17,7 +17,7 @@ chip soc/intel/cannonlake device pci 12.5 alias ufs off end # UFS SCS device pci 12.6 alias gspi2 off ops spi_dev_ops end # GSPI #2 device pci 13.0 alias ish off end # ISH - device pci 14.0 alias xhci off # USB xHCI + device pci 14.0 alias xhci off ops usb_xhci_ops # USB xHCI chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/cannonlake/chipset_pch_h.cb b/src/soc/intel/cannonlake/chipset_pch_h.cb index 240054d3bf..9d96061bf1 100644 --- a/src/soc/intel/cannonlake/chipset_pch_h.cb +++ b/src/soc/intel/cannonlake/chipset_pch_h.cb @@ -17,7 +17,7 @@ chip soc/intel/cannonlake device pci 12.5 alias ufs off end # UFS SCS device pci 12.6 alias gspi2 off ops spi_dev_ops end # GSPI #2 device pci 13.0 alias ish off end # ISH - device pci 14.0 alias xhci off # USB xHCI + device pci 14.0 alias xhci off ops usb_xhci_ops # USB xHCI chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/common/block/xhci/xhci.c b/src/soc/intel/common/block/xhci/xhci.c index 5eb73ed562..a7b56e8d5c 100644 --- a/src/soc/intel/common/block/xhci/xhci.c +++ b/src/soc/intel/common/block/xhci/xhci.c @@ -132,29 +132,10 @@ struct device_operations usb_xhci_ops = { static const unsigned short pci_device_ids[] = { PCI_DID_INTEL_NVL_XHCI, - PCI_DID_INTEL_WCL_XHCI, - PCI_DID_INTEL_PTL_H_XHCI, - PCI_DID_INTEL_PTL_U_H_XHCI, PCI_DID_INTEL_LNL_XHCI, - PCI_DID_INTEL_MTL_XHCI, - PCI_DID_INTEL_ARL_XHCI, - PCI_DID_INTEL_ARP_S_XHCI, - PCI_DID_INTEL_APL_XHCI, - PCI_DID_INTEL_CNL_LP_XHCI, - PCI_DID_INTEL_GLK_XHCI, PCI_DID_INTEL_LWB_XHCI, PCI_DID_INTEL_LWB_XHCI_SUPER, - PCI_DID_INTEL_CNP_H_XHCI, - PCI_DID_INTEL_CMP_LP_XHCI, - PCI_DID_INTEL_CMP_H_XHCI, - PCI_DID_INTEL_TGP_LP_XHCI, - PCI_DID_INTEL_TGP_H_XHCI, PCI_DID_INTEL_MCC_XHCI, - PCI_DID_INTEL_JSP_XHCI, - PCI_DID_INTEL_ADP_P_XHCI, - PCI_DID_INTEL_ADP_S_XHCI, - PCI_DID_INTEL_ADP_M_XHCI, - PCI_DID_INTEL_RPP_S_XHCI, PCI_DID_INTEL_SNR_XHCI, 0 }; diff --git a/src/soc/intel/jasperlake/chipset.cb b/src/soc/intel/jasperlake/chipset.cb index ca18683d8b..c6cc992ae6 100644 --- a/src/soc/intel/jasperlake/chipset.cb +++ b/src/soc/intel/jasperlake/chipset.cb @@ -12,7 +12,7 @@ chip soc/intel/jasperlake device pci 12.0 alias ish off end device pci 12.5 alias ufs_scs off end device pci 12.6 alias gspi2 off ops spi_dev_ops end - device pci 14.0 alias south_xhci off + device pci 14.0 alias south_xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/meteorlake/chipset.cb b/src/soc/intel/meteorlake/chipset.cb index a1b995c5c9..df62835b56 100644 --- a/src/soc/intel/meteorlake/chipset.cb +++ b/src/soc/intel/meteorlake/chipset.cb @@ -100,7 +100,7 @@ chip soc/intel/meteorlake device pci 13.1 alias ieh2 off end device pci 13.2 alias pmc2 hidden end device pci 13.3 alias ioe_shared_sram off end - device pci 14.0 alias xhci off + device pci 14.0 alias xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/pantherlake/chipset_ptl.cb b/src/soc/intel/pantherlake/chipset_ptl.cb index e2277d319c..82dc449d80 100644 --- a/src/soc/intel/pantherlake/chipset_ptl.cb +++ b/src/soc/intel/pantherlake/chipset_ptl.cb @@ -174,7 +174,7 @@ chip soc/intel/pantherlake device pci 13.0 alias heci_1 off end device pci 13.1 alias heci_2 off end device pci 13.2 alias heci_3 off end - device pci 14.0 alias xhci on + device pci 14.0 alias xhci on ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/pantherlake/chipset_wcl.cb b/src/soc/intel/pantherlake/chipset_wcl.cb index 0cb6e6634e..ccc5948d1f 100644 --- a/src/soc/intel/pantherlake/chipset_wcl.cb +++ b/src/soc/intel/pantherlake/chipset_wcl.cb @@ -60,7 +60,7 @@ chip soc/intel/pantherlake device pci 13.0 alias heci_1 off end device pci 13.1 alias heci_2 off end device pci 13.2 alias heci_3 off end - device pci 14.0 alias xhci on + device pci 14.0 alias xhci on ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/tigerlake/chipset.cb b/src/soc/intel/tigerlake/chipset.cb index 40932489da..9594917ef8 100644 --- a/src/soc/intel/tigerlake/chipset.cb +++ b/src/soc/intel/tigerlake/chipset.cb @@ -63,7 +63,7 @@ chip soc/intel/tigerlake device pci 12.0 alias ish off end device pci 12.6 alias gspi2 off ops spi_dev_ops end device pci 13.0 alias gspi3 off ops spi_dev_ops end - device pci 14.0 alias south_xhci off + device pci 14.0 alias south_xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off diff --git a/src/soc/intel/tigerlake/chipset_pch_h.cb b/src/soc/intel/tigerlake/chipset_pch_h.cb index 3761527edb..8b0355a443 100644 --- a/src/soc/intel/tigerlake/chipset_pch_h.cb +++ b/src/soc/intel/tigerlake/chipset_pch_h.cb @@ -67,7 +67,7 @@ chip soc/intel/tigerlake device pci 12.0 alias ish off end device pci 12.6 alias gspi2 off ops spi_dev_ops end device pci 13.0 alias gspi3 off ops spi_dev_ops end - device pci 14.0 alias south_xhci off + device pci 14.0 alias south_xhci off ops usb_xhci_ops chip drivers/usb/acpi register "type" = "UPC_TYPE_HUB" device usb 0.0 alias xhci_root_hub off