From: Ruiyu Ni Date: Thu, 4 Jan 2018 05:39:11 +0000 (+0800) Subject: MdeModulePkg/PciBus: Reserve Bus number for non-root and root HPBs X-Git-Tag: edk2-stable201903~2659 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=cbbccf3cf39247456746949dfaa00ff4bbc6826f MdeModulePkg/PciBus: Reserve Bus number for non-root and root HPBs REF: https://bugzilla.tianocore.org/show_bug.cgi?id=656 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Reviewed-by: Laszlo Ersek Tested-by: Laszlo Ersek --- diff --git a/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c b/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c index a3a5829582..dc1086606f 100644 --- a/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c +++ b/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c @@ -1125,14 +1125,14 @@ PciScanBus ( BusPadding = FALSE; if (gPciHotPlugInit != NULL) { - if (IsRootPciHotPlugBus (PciDevice->DevicePath, &HpIndex)) { + if (IsPciHotPlugBus (PciDevice)) { // // If it is initialized, get the padded bus range // Status = gPciHotPlugInit->GetResourcePadding ( gPciHotPlugInit, - gPciRootHpcPool[HpIndex].HpbDevicePath, + PciDevice->DevicePath, PciAddress, &State, (VOID **) &Descriptors,