]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ShellPkg: update pci enumeration routine for platforms with multiple pci segments.
authorjcarsey <jcarsey@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 11 Jul 2012 19:08:40 +0000 (19:08 +0000)
committerjcarsey <jcarsey@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 11 Jul 2012 19:08:40 +0000 (19:08 +0000)
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eugene Cohen eugene@hp.com
reviewed-by: jaben carsey <jaben.carsey@intel.com>

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13524 6f19259b-4bc3-4df7-8a09-765794883524

ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c

index 017c33780a6935a31901ace060c384f7127eef49..ce55d6e33256c85b34f53e35ff96e0867a89c54d 100644 (file)
@@ -2464,13 +2464,11 @@ PciFindProtocolInterface (
 {\r
   UINTN                             Index;\r
   EFI_STATUS                        Status;\r
-  BOOLEAN                           FoundInterface;\r
   EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR *Descriptors;\r
   UINT16                            MinBus;\r
   UINT16                            MaxBus;\r
   BOOLEAN                           IsEnd;\r
 \r
-  FoundInterface = FALSE;\r
   //\r
   // Go through all handles, until the one meets the criteria is found\r
   //\r
@@ -2502,17 +2500,12 @@ PciFindProtocolInterface (
       }\r
 \r
       if (MinBus <= Bus && MaxBus >= Bus) {\r
-        FoundInterface = TRUE;\r
-        break;\r
+        return EFI_SUCCESS;\r
       }\r
     }\r
   }\r
 \r
-  if (FoundInterface) {\r
-    return EFI_SUCCESS;\r
-  } else {\r
-    return EFI_INVALID_PARAMETER;\r
-  }\r
+  return EFI_NOT_FOUND;\r
 }\r
 \r
 /**\r