diff options
author | Gary Lin <glin@suse.com> | 2016-05-11 16:40:49 +0800 |
---|---|---|
committer | Laszlo Ersek <lersek@redhat.com> | 2016-05-12 10:25:15 +0200 |
commit | 14b2ebc30c8bc98f668fa78171b659e2cdc33aa5 (patch) | |
tree | 52a0cc553269bdf3c6fba2277f68053e5b9679d0 /OvmfPkg | |
parent | e117c894fdf1896fea5d37057832fed58d48b6ee (diff) | |
download | edk2-14b2ebc30c8bc98f668fa78171b659e2cdc33aa5.tar.gz edk2-14b2ebc30c8bc98f668fa78171b659e2cdc33aa5.tar.bz2 edk2-14b2ebc30c8bc98f668fa78171b659e2cdc33aa5.zip |
OvmfPkg/PlatformBootManagerLib: Postpone the shell registration
We currently register the shell before creating the boot options for
the block devices and the network devices, so the boot manager boots
into the internal shell if the user doesn't specify the boot order.
However, Xen doesn't support fw_cfg, so there is no way to change the
boot order with the external command, and the firmware will always
boot into the internal shell if the user doesn't interfere the boot
process.
This patch postpones the shell registration after MdeModulePkg/BDS
creates all the boot options for the block and network devices, so
that firmware will try to boot the block/network devices first.
Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Gary Lin <glin@suse.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
Diffstat (limited to 'OvmfPkg')
-rw-r--r-- | OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c b/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c index cf774a16a7..a16453d289 100644 --- a/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c +++ b/OvmfPkg/Library/PlatformBootManagerLib/BdsPlatform.c @@ -184,12 +184,6 @@ PlatformRegisterOptionsAndKeys ( NULL, (UINT16) BootOption.OptionNumber, 0, &Esc, NULL
);
ASSERT (Status == EFI_SUCCESS || Status == EFI_ALREADY_STARTED);
- //
- // Register UEFI Shell
- //
- PlatformRegisterFvBootOption (
- PcdGetPtr (PcdShellFile), L"EFI Internal Shell", LOAD_OPTION_ACTIVE
- );
}
EFI_STATUS
@@ -1304,6 +1298,13 @@ Routine Description: EfiBootManagerRefreshAllBootOption ();
+ //
+ // Register UEFI Shell
+ //
+ PlatformRegisterFvBootOption (
+ PcdGetPtr (PcdShellFile), L"EFI Internal Shell", LOAD_OPTION_ACTIVE
+ );
+
SetBootOrderFromQemu (NULL);
}
|