Attention is currently required from: Patrick Rudolph. Maulik V Vaghela has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/61975 )
Change subject: soc/intelblocks: Add function to determine if PCIe group is TBT ......................................................................
soc/intelblocks: Add function to determine if PCIe group is TBT
PCIe port remapping logic requires to determine if PCIe port belongs to TBT or PCH in order to correctly remap the ports.
This patch adds weak function to check if PCIe group belongs to TBT. Bydefault it returns false to retain current flow for remap function but Each SoC can implement strong function to return correct value.
BUG=b:210933428 BRANCH=None TEST=Code compilation is fine for Brya and other ADL boards.
Change-Id: If196dde275ea6080fd8e7ae4361c18e830a3c109 Signed-off-by: MAULIK V VAGHELA maulik.v.vaghela@intel.com --- M src/soc/intel/common/block/include/intelblocks/pcie_rp.h M src/soc/intel/common/block/pcie/pcie_rp.c 2 files changed, 7 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/75/61975/1
diff --git a/src/soc/intel/common/block/include/intelblocks/pcie_rp.h b/src/soc/intel/common/block/include/intelblocks/pcie_rp.h index b43987d..ed3c99b 100644 --- a/src/soc/intel/common/block/include/intelblocks/pcie_rp.h +++ b/src/soc/intel/common/block/include/intelblocks/pcie_rp.h @@ -126,5 +126,7 @@
/* Return the virtual wire index that represents CPU-side PCIe root ports */ int soc_get_cpu_rp_vw_idx(const struct device *dev); +/* Return if current PCIe slot is TBT PCIe or not */ +bool is_tbt_slot(struct pcie_rp_group *const group);
#endif /* SOC_INTEL_COMMON_BLOCK_PCIE_RP_H */ diff --git a/src/soc/intel/common/block/pcie/pcie_rp.c b/src/soc/intel/common/block/pcie/pcie_rp.c index 221ee03..3347f2d 100644 --- a/src/soc/intel/common/block/pcie/pcie_rp.c +++ b/src/soc/intel/common/block/pcie/pcie_rp.c @@ -10,6 +10,11 @@ #include <device/pci_type.h> #include <intelblocks/pcie_rp.h>
+__weak bool is_tbt_slot(struct pcie_rp_group *const group) +{ + return false; +} + static int pcie_rp_original_idx( const struct pcie_rp_group *const group, const unsigned int offset,