summaryrefslogtreecommitdiffstats
path: root/UefiPayloadPkg/Library
diff options
context:
space:
mode:
authorMarsX Lin <marsx.lin@intel.com>2023-07-10 16:21:23 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2023-07-11 06:36:11 +0000
commit8dab4eebe435fc28cae329867a74cee45d040d3e (patch)
treeebf850f2b642dfd4b341a3c5b2d9c4d5f4911fdf /UefiPayloadPkg/Library
parent964a4f032dcd15d7b0d9246625b13b71182e4eae (diff)
downloadedk2-8dab4eebe435fc28cae329867a74cee45d040d3e.tar.gz
edk2-8dab4eebe435fc28cae329867a74cee45d040d3e.tar.bz2
edk2-8dab4eebe435fc28cae329867a74cee45d040d3e.zip
UefiPayloadPkg: Integrate UiApp and BootManagerMenuApp into MultiFv
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4347 To put UiApp.inf and BootManagerMenuApp.inf to proper FV(BDSFV) Cc: Guo Dong <guo.dong@intel.com> Cc: Ray Ni <ray.ni@intel.com> Cc: Sean Rhodes <sean@starlabs.systems> Reviewed-by: James Lu <james.lu@intel.com> Reviewed-by: Gua Guo <gua.guo@intel.com> Signed-off-by: MarsX Lin <marsx.lin@intel.com>
Diffstat (limited to 'UefiPayloadPkg/Library')
-rw-r--r--UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.c55
-rw-r--r--UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf4
2 files changed, 0 insertions, 59 deletions
diff --git a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.c b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.c
index 4a0219624d..a4a49da0e9 100644
--- a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.c
+++ b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManager.c
@@ -9,8 +9,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
#include "PlatformBootManager.h"
#include "PlatformConsole.h"
-#include <Guid/BootManagerMenu.h>
-#include <Library/HobLib.h>
#include <Protocol/FirmwareVolume2.h>
/**
@@ -364,56 +362,3 @@ PlatformBootManagerUnableToBoot (
{
return;
}
-
-/**
- Get/update PcdBootManagerMenuFile from GUID HOB which will be assigned in bootloader.
-
- @param ImageHandle The firmware allocated handle for the EFI image.
- @param SystemTable A pointer to the EFI System Table.
-
- @retval EFI_SUCCESS The entry point is executed successfully.
- @retval other Some error occurs.
-
-**/
-EFI_STATUS
-EFIAPI
-PlatformBootManagerLibConstructor (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- )
-{
- EFI_STATUS Status;
- UINTN Size;
- VOID *GuidHob;
- UNIVERSAL_PAYLOAD_GENERIC_HEADER *GenericHeader;
- UNIVERSAL_PAYLOAD_BOOT_MANAGER_MENU *BootManagerMenuFile;
-
- GuidHob = GetFirstGuidHob (&gEdkiiBootManagerMenuFileGuid);
-
- if (GuidHob == NULL) {
- //
- // If the HOB is not create, the default value of PcdBootManagerMenuFile will be used.
- //
- return EFI_SUCCESS;
- }
-
- GenericHeader = (UNIVERSAL_PAYLOAD_GENERIC_HEADER *)GET_GUID_HOB_DATA (GuidHob);
- if ((sizeof (UNIVERSAL_PAYLOAD_GENERIC_HEADER) > GET_GUID_HOB_DATA_SIZE (GuidHob)) || (GenericHeader->Length > GET_GUID_HOB_DATA_SIZE (GuidHob))) {
- return EFI_NOT_FOUND;
- }
-
- if (GenericHeader->Revision == UNIVERSAL_PAYLOAD_BOOT_MANAGER_MENU_REVISION) {
- BootManagerMenuFile = (UNIVERSAL_PAYLOAD_BOOT_MANAGER_MENU *)GET_GUID_HOB_DATA (GuidHob);
- if (BootManagerMenuFile->Header.Length < UNIVERSAL_PAYLOAD_SIZEOF_THROUGH_FIELD (UNIVERSAL_PAYLOAD_BOOT_MANAGER_MENU, FileName)) {
- return EFI_NOT_FOUND;
- }
-
- Size = sizeof (BootManagerMenuFile->FileName);
- Status = PcdSetPtrS (PcdBootManagerMenuFile, &Size, &BootManagerMenuFile->FileName);
- ASSERT_EFI_ERROR (Status);
- } else {
- return EFI_NOT_FOUND;
- }
-
- return EFI_SUCCESS;
-}
diff --git a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf
index a3951b7a7e..ff92c95227 100644
--- a/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf
+++ b/UefiPayloadPkg/Library/PlatformBootManagerLib/PlatformBootManagerLib.inf
@@ -13,7 +13,6 @@
MODULE_TYPE = DXE_DRIVER
VERSION_STRING = 1.0
LIBRARY_CLASS = PlatformBootManagerLib|DXE_DRIVER
- CONSTRUCTOR = PlatformBootManagerLibConstructor
#
# The following information is for reference only and not required by the build tools.
@@ -48,11 +47,9 @@
HiiLib
PrintLib
PlatformHookLib
- HobLib
[Guids]
gEfiEndOfDxeEventGroupGuid
- gEdkiiBootManagerMenuFileGuid
gUefiShellFileGuid
[Protocols]
@@ -75,5 +72,4 @@
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultDataBits
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultStopBits
- gEfiMdeModulePkgTokenSpaceGuid.PcdBootManagerMenuFile
gUefiPayloadPkgTokenSpaceGuid.PcdBootManagerEscape