summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKavya <k.kavyax.sravanthi@intel.com>2022-08-22 18:49:30 +0530
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2022-08-23 01:04:17 +0000
commit2bb002067565fcf16641dfc9ba9d0f68e17bfc8f (patch)
tree774e4458fd4c9a7331305b90c82673139c20c1a2
parentd5fd86f256b9ab5b4e3aff70d3c177c18faea892 (diff)
downloadedk2-2bb002067565fcf16641dfc9ba9d0f68e17bfc8f.tar.gz
edk2-2bb002067565fcf16641dfc9ba9d0f68e17bfc8f.tar.bz2
edk2-2bb002067565fcf16641dfc9ba9d0f68e17bfc8f.zip
UefiPayloadPkg: Return PciRootBridges instead of NULL
Return PciRootBridges instead of NULL and set PcdPciDisableBusEnumeration to FALSE when root bridge count is zero. Reviewed-by: Guo Dong <guo.dong@intel.com> Reviewed-by: Gua Guo <gua.guo@intel.com> Signed-off-by: Kavya <k.kavyax.sravanthi@intel.com>
-rw-r--r--UefiPayloadPkg/Library/PciHostBridgeLib/PciHostBridgeSupport.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/UefiPayloadPkg/Library/PciHostBridgeLib/PciHostBridgeSupport.c b/UefiPayloadPkg/Library/PciHostBridgeLib/PciHostBridgeSupport.c
index e1faa24ae7..fb76853072 100644
--- a/UefiPayloadPkg/Library/PciHostBridgeLib/PciHostBridgeSupport.c
+++ b/UefiPayloadPkg/Library/PciHostBridgeLib/PciHostBridgeSupport.c
@@ -549,6 +549,7 @@ RetrieveRootBridgeInfoFromHob (
}
if (PciRootBridgeInfo->Count == 0) {
+ PcdSetBoolS (PcdPciDisableBusEnumeration, FALSE);
return NULL;
}
@@ -589,9 +590,8 @@ RetrieveRootBridgeInfoFromHob (
if (PciRootBridgeInfo->ResourceAssigned) {
PcdSetBoolS (PcdPciDisableBusEnumeration, TRUE);
} else {
- DEBUG ((DEBUG_ERROR, "There is root bridge whose ResourceAssigned is FALSE\n"));
+ DEBUG ((DEBUG_INFO, "There is root bridge whose ResourceAssigned is FALSE\n"));
PcdSetBoolS (PcdPciDisableBusEnumeration, FALSE);
- return NULL;
}
return PciRootBridges;