]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ArmPkg/PlatformBootManagerLib: refer to Shell FILE_GUID directly
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Sat, 18 Mar 2017 21:18:42 +0000 (21:18 +0000)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Wed, 22 Mar 2017 15:33:42 +0000 (15:33 +0000)
Instead of indirecting the reference to the Shell binary via a PCD
that is defined in IntelFrameworkModulePkg, and which invariably
gets set to the same value by all users of this library, refer to
the UEFI Shell application by its declared symbolic GUID.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
ArmPkg/Library/PlatformBootManagerLib/PlatformBm.c
ArmPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf

index 67e87c1c26421ed3e8d9dc5f6d995dffca039337..bb21bb65d5facc448279696941cb2951ce13fc94 100644 (file)
@@ -33,7 +33,6 @@
 \r
 #define DP_NODE_LEN(Type) { (UINT8)sizeof (Type), (UINT8)(sizeof (Type) >> 8) }\r
 \r
-\r
 #pragma pack (1)\r
 typedef struct {\r
   VENDOR_DEVICE_PATH         SerialDxe;\r
@@ -327,7 +326,7 @@ AddOutput (
 STATIC\r
 VOID\r
 PlatformRegisterFvBootOption (\r
-  EFI_GUID                         *FileGuid,\r
+  CONST EFI_GUID                   *FileGuid,\r
   CHAR16                           *Description,\r
   UINT32                           Attributes\r
   )\r
@@ -535,7 +534,7 @@ PlatformBootManagerAfterConsole (
   // Register UEFI Shell\r
   //\r
   PlatformRegisterFvBootOption (\r
-    PcdGetPtr (PcdShellFile), L"UEFI Shell", LOAD_OPTION_ACTIVE\r
+    &gUefiShellFileGuid, L"UEFI Shell", LOAD_OPTION_ACTIVE\r
     );\r
 }\r
 \r
index 8ec4f1dea6c4cd0fc67da4294ae315c10f321419..beca5800d6493aeef1e99c505572f3aec3e1200c 100644 (file)
@@ -39,6 +39,7 @@
   IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec\r
   MdeModulePkg/MdeModulePkg.dec\r
   MdePkg/MdePkg.dec\r
+  ShellPkg/ShellPkg.dec\r
 \r
 [LibraryClasses]\r
   BaseLib\r
@@ -59,7 +60,6 @@
 \r
 [FixedPcd]\r
   gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile\r
-  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile\r
   gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate\r
   gEfiMdePkgTokenSpaceGuid.PcdUartDefaultDataBits\r
   gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity\r
@@ -75,6 +75,7 @@
   gEfiFileSystemVolumeLabelInfoIdGuid\r
   gEfiEndOfDxeEventGroupGuid\r
   gEfiTtyTermGuid\r
+  gUefiShellFileGuid\r
 \r
 [Protocols]\r
   gEfiDevicePathProtocolGuid\r