]> git.proxmox.com Git - mirror_edk2.git/commitdiff
PciBusDxe: duplicate node insertion for every PPB device in the system
authorJaveed, Ashraf <ashraf.javeed@intel.com>
Mon, 27 May 2019 10:23:56 +0000 (18:23 +0800)
committerHao A Wu <hao.a.wu@intel.com>
Mon, 1 Jul 2019 07:36:09 +0000 (15:36 +0800)
https://bugzilla.tianocore.org/show_bug.cgi?id=1796
Bug fixed in PciBusDxe\PciLib.c.
Removed the redundant second call to PciSearchDevice sub-routine when the
PCD for the Hot-Plug support is disabled.

Signed-off-by: Ashraf Javeed <Ashraf.javeed@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Acked-by: Hao A Wu <hao.a.wu@intel.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Ray Ni <ray.ni@intel.com>
MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c

index f0d9f45c4afc7fe41a84575c49caeb6985072d58..5b55fb5d3be4d83ebd9c8e2706e493bc80cb2667 100644 (file)
@@ -1114,24 +1114,7 @@ PciScanBus (
         //\r
         // For PPB\r
         //\r
-        if (!FeaturePcdGet (PcdPciBusHotplugDeviceSupport)) {\r
-          //\r
-          // If Hot Plug is not supported,\r
-          // get the bridge information\r
-          //\r
-          Status = PciSearchDevice (\r
-                    Bridge,\r
-                    &Pci,\r
-                    StartBusNumber,\r
-                    Device,\r
-                    Func,\r
-                    &PciDevice\r
-                    );\r
-\r
-          if (EFI_ERROR (Status)) {\r
-            return Status;\r
-          }\r
-        } else {\r
+        if (FeaturePcdGet (PcdPciBusHotplugDeviceSupport)) {\r
           //\r
           // If Hot Plug is supported,\r
           // Get the bridge information\r