You've already forked edk2-upstream
mirror of
https://github.com/Dasharo/edk2-upstream.git
synced 2026-03-06 15:03:57 -08:00
OvmfPkg/PlatformBootManagerLib: Register UiApp as an optional boot option
Introduce gUiAppFileGuid: it has the same value of UiApp guid defined in the .inf file. This is used to register UiApp as a boot entry in the BootManagerMenu. This registration is done in PlatformBootManagerBeforeConsole because it must be done before the hotkeys are registered. This is because in a system with hotkeys still bound to UiApp, but with firmware disabled, you can still boot into the latter by hitting ESC or F2 during boot. UiApp can be enabled/disabled using fw_cfg option FirmwareSetupSupport Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Luigi Leonardi <leonardi@redhat.com>
This commit is contained in:
committed by
mergify[bot]
parent
896907b53b
commit
d433b4c8e4
@@ -221,6 +221,7 @@ PlatformBootManagerBeforeConsole (
|
||||
EFI_STATUS Status;
|
||||
UINT16 FrontPageTimeout;
|
||||
RETURN_STATUS PcdStatus;
|
||||
BOOLEAN FirmwareSetupEnabled;
|
||||
|
||||
DEBUG ((DEBUG_INFO, "PlatformBootManagerBeforeConsole\n"));
|
||||
InstallDevicePathCallback ();
|
||||
@@ -320,6 +321,22 @@ PlatformBootManagerBeforeConsole (
|
||||
Status
|
||||
));
|
||||
|
||||
Status = QemuFwCfgParseBool (
|
||||
"opt/org.tianocore/FirmwareSetupSupport",
|
||||
&FirmwareSetupEnabled
|
||||
);
|
||||
|
||||
if (RETURN_ERROR (Status)) {
|
||||
FirmwareSetupEnabled = TRUE;
|
||||
}
|
||||
|
||||
PlatformRegisterFvBootOption (
|
||||
&gUiAppFileGuid,
|
||||
L"EFI Firmware Setup",
|
||||
LOAD_OPTION_ACTIVE | LOAD_OPTION_CATEGORY_APP,
|
||||
FirmwareSetupEnabled
|
||||
);
|
||||
|
||||
if (!FeaturePcdGet (PcdBootRestrictToFirmware)) {
|
||||
PlatformRegisterOptionsAndKeys ();
|
||||
}
|
||||
|
||||
@@ -89,3 +89,4 @@
|
||||
gRootBridgesConnectedEventGroupGuid
|
||||
gUefiShellFileGuid
|
||||
gGrubFileGuid
|
||||
gUiAppFileGuid
|
||||
|
||||
@@ -168,6 +168,7 @@
|
||||
gMicrosoftVendorGuid = {0x77fa9abd, 0x0359, 0x4d32, {0xbd, 0x60, 0x28, 0xf4, 0xe7, 0x8f, 0x78, 0x4b}}
|
||||
gQemuKernelLoaderFsMediaGuid = {0x1428f772, 0xb64a, 0x441e, {0xb8, 0xc3, 0x9e, 0xbd, 0xd7, 0xf8, 0x93, 0xc7}}
|
||||
gGrubFileGuid = {0xb5ae312c, 0xbc8a, 0x43b1, {0x9c, 0x62, 0xeb, 0xb8, 0x26, 0xdd, 0x5d, 0x07}}
|
||||
gUiAppFileGuid = {0x462CAA21, 0x7614, 0x4503, {0x83, 0x6E, 0x8A, 0xB6, 0xF4, 0x66, 0x23, 0x31}}
|
||||
gConfidentialComputingSecretGuid = {0xadf956ad, 0xe98c, 0x484c, {0xae, 0x11, 0xb5, 0x1c, 0x7d, 0x33, 0x64, 0x47}}
|
||||
gConfidentialComputingSevSnpBlobGuid = {0x067b1f5f, 0xcf26, 0x44c5, {0x85, 0x54, 0x93, 0xd7, 0x77, 0x91, 0x2d, 0x42}}
|
||||
gUefiOvmfPkgPlatformInfoGuid = {0xdec9b486, 0x1f16, 0x47c7, {0x8f, 0x68, 0xdf, 0x1a, 0x41, 0x88, 0x8b, 0xa5}}
|
||||
|
||||
Reference in New Issue
Block a user