]> git.proxmox.com Git - mirror_edk2.git/commitdiff
ArmVirtPkg/PlatformBootManagerLib: use EfiBootManagerUpdateConsoleVariable
authorLaszlo Ersek <lersek@redhat.com>
Thu, 5 May 2016 13:58:56 +0000 (15:58 +0200)
committerLaszlo Ersek <lersek@redhat.com>
Fri, 6 May 2016 08:04:49 +0000 (10:04 +0200)
In this rather mechanical patch, we replace the calls to GenericBdsLib's
BdsLibUpdateConsoleVariable() with calls to UefiBootManagerLib's
EfiBootManagerUpdateConsoleVariable(), which has the same purpose.

The latter uses CONSOLE_TYPE enum constants from
"MdeModulePkg/Include/Library/UefiBootManagerLib.h", for identifying the
console type / underlying UEFI variable in the first parameter.

This patch parallels OvmfPkg commit 9dc08ec6574b.

Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Ruiyu Ni <ruiyu.ni@Intel.com>
ArmVirtPkg/Library/PlatformBootManagerLib/PlatformBm.c

index 4920621e5d19f23fd1d00ccf6bfc38b3d87ccda0..56f0ea8ff77a8ba8ab2a597f06908aa1d5d3f1ee 100644 (file)
@@ -329,14 +329,14 @@ AddOutput (
     return;\r
   }\r
 \r
-  Status = BdsLibUpdateConsoleVariable (L"ConOut", DevicePath, NULL);\r
+  Status = EfiBootManagerUpdateConsoleVariable (ConOut, DevicePath, NULL);\r
   if (EFI_ERROR (Status)) {\r
     DEBUG ((EFI_D_ERROR, "%a: %s: adding to ConOut: %r\n", __FUNCTION__,\r
       ReportText, Status));\r
     return;\r
   }\r
 \r
-  Status = BdsLibUpdateConsoleVariable (L"ErrOut", DevicePath, NULL);\r
+  Status = EfiBootManagerUpdateConsoleVariable (ErrOut, DevicePath, NULL);\r
   if (EFI_ERROR (Status)) {\r
     DEBUG ((EFI_D_ERROR, "%a: %s: adding to ErrOut: %r\n", __FUNCTION__,\r
       ReportText, Status));\r
@@ -393,7 +393,7 @@ PlatformBootManagerAfterConsole (
   //\r
   // Add the hardcoded short-form USB keyboard device path to ConIn.\r
   //\r
-  BdsLibUpdateConsoleVariable (L"ConIn",\r
+  EfiBootManagerUpdateConsoleVariable (ConIn,\r
     (EFI_DEVICE_PATH_PROTOCOL *)&mUsbKeyboard, NULL);\r
 \r
   //\r
@@ -401,11 +401,11 @@ PlatformBootManagerAfterConsole (
   //\r
   CopyGuid (&mSerialConsole.TermType.Guid,\r
     PcdGetPtr (PcdTerminalTypeGuidBuffer));\r
-  BdsLibUpdateConsoleVariable (L"ConIn",\r
+  EfiBootManagerUpdateConsoleVariable (ConIn,\r
     (EFI_DEVICE_PATH_PROTOCOL *)&mSerialConsole, NULL);\r
-  BdsLibUpdateConsoleVariable (L"ConOut",\r
+  EfiBootManagerUpdateConsoleVariable (ConOut,\r
     (EFI_DEVICE_PATH_PROTOCOL *)&mSerialConsole, NULL);\r
-  BdsLibUpdateConsoleVariable (L"ErrOut",\r
+  EfiBootManagerUpdateConsoleVariable (ErrOut,\r
     (EFI_DEVICE_PATH_PROTOCOL *)&mSerialConsole, NULL);\r
 \r
   //\r