summaryrefslogtreecommitdiffstats
path: root/OvmfPkg/Library/PlatformBootManagerLib
Commit message (Collapse)AuthorAgeFilesLines
...
* OvmfPkg/PlatformBootManagerLib: keep the logo after connecting devicesLaszlo Ersek2016-05-271-5/+0
| | | | | | | | | | | | | OVMF (unlike ArmVirtPkg) has traditionally cleared the screen after connecting devices. This is not really necessary, and keeping the logo up while the progress bar is advancing at the bottom looks great. So don't clear the screen. 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: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* OvmfPkg/PlatformBootManagerLib: bring back the progress barLaszlo Ersek2016-05-271-0/+17
| | | | | | | | | | | | | | | | | | OVMF's Platform BDS used to have a nice progress bar (with IntelFrameworkModulePkg BDS). We can restore it by copying the PlatformBootManagerWaitCallback() function verbatim from Nt32Pkg/Library/PlatformBootManagerLib/PlatformBootManager.c It can be tested by passing the following option to QEMU (5 seconds): -boot menu=on,splash-time=5000 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: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* OvmfPkg/PlatformBootManagerLib: rebase boot logo display to BootLogoLibLaszlo Ersek2016-05-274-712/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the course of porting OvmfPkg to the MdeModulePkg BDS, commit 817fb3ac2a78 OvmfPkg/PlatformBootManagerLib: Add EnableQuietBoot & DisableQuietBoot open-coded the EnableQuietBoot() function (and its dependencies / friends) from IntelFrameworkModulePkg BDS. This code duplication can be avoided; the functionality is available from the following three libraries in MdeModulePkg: - BootLogoLib: provides the BootLogoEnableLogo() function. It does not provide the internal ConvertBmpToGopBlt() function -- that one is delegated to ImageDecoderLib (function DecodeImage()). - ImageDecoderLib: a general library that registers decoder plugins for specific image formats, and provides the generic DecodeImage() on top. - BmpImageDecoderLib: one of said decoder plugins, for handling BMP images (which is the format of our logo). In this patch, we revert 817fb3ac2a78, and atomically incorporate the above libraries. This is inspired by Nt32Pkg commit 859e75c4fc42: Nt32Pkg: Use BootLogoLib for logo and progress bar drawing. 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: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* OvmfPkg, ArmVirtPkg: clean up SetBootOrderFromQemu() parameter listLaszlo Ersek2016-05-251-1/+1
| | | | | | | | | | | | | | | | With OvmfPkg's original QemuBootOrderLib (and USE_OLD_BDS) gone, we no longer need the BootOptionList parameter in the SetBootOrderFromQemu() prototype. Update the library class header file (including the function's documentation), and adapt the library instance and the call sites. Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org> Cc: Gary Ching-Pang Lin <glin@suse.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: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
* OvmfPkg/PlatformBootManagerLib: Postpone the shell registrationGary Lin2016-05-121-6/+7
| | | | | | | | | | | | | | | | | | | | | | 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>
* OvmfPkg/PlatformBootManagerLib: Remove unused C structures definitionsRuiyu Ni2016-05-041-47/+0
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Fix gcc-4.8 Ia32 build failureRuiyu Ni2016-05-041-0/+2
| | | | | | | | | | | | | | | | The Width and Height assignment suppresses an invalid gcc-4.8 warning on Ia32. These warnings look unjustified to me. Namely, near the beginning of the function, there is a while(1) loop. In that loop, ConvertBmpToGopBlt() is called unconditionally. If the call fails, the rest of the loop body is not reached (where the Height and Width variables are used -- the compiler warns about their use in the switch statement). If the call succeeds, then the variables are set. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Add EnableQuietBoot & DisableQuietBootRuiyu Ni2016-05-043-0/+709
| | | | | | | | | | EnableQuietBoot and DisableQuietBoot are copied from IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c. Because these two functions are not in UefiBootManagerLib. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Remove unused vars and func prototypesRuiyu Ni2016-05-042-53/+1
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Remove unnecessary memory testRuiyu Ni2016-05-042-63/+2
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Use GetBootModeHob() in HobLibRuiyu Ni2016-05-041-2/+1
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Remove PlatformBdsGetDriverOption()Ruiyu Ni2016-05-042-36/+0
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Use EfiBootManagerRefreshAllBootOption()Ruiyu Ni2016-05-042-8/+4
| | | | | | | | | | The patch uses EfiBootManagerRefreshAllBootOption() to collect all boot options and uses SetBootOrderFromQemu exposed by QemuNewBootOrderLib to adjust the boot option order. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: port PlatformBdsConnectSequence to ↵Ruiyu Ni2016-05-041-6/+3
| | | | | | | | | | | | UefiBootManagerLib The patch changes PlatformBdsConnectSequence() to use library API exposed from UefiBootManagerLib and removes the additional connect ALL action. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Remove unused local functions.Ruiyu Ni2016-05-041-94/+0
| | | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Cc: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Register boot options and hot keysRuiyu Ni2016-05-043-0/+110
| | | | | | | | | | | The patch registers "Enter" key as the continue key (hot key to skip the boot timeout wait), maps "F2" key to UI, and registers Shell boot option. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Do not launch Boot Manager MenuRuiyu Ni2016-05-043-8/+2
| | | | | | | | | | | MdeModulePkg/BDS doesn't launch UI (Boot Manager Menu) from platform side. The change removes the code which launches the UI but still set the boot timeout. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Init console vars in *BeforeConsole()Ruiyu Ni2016-05-043-109/+21
| | | | | | | | | | | | | | | The major difference between IntelFrameworkModulePkg/BDS and MdeModulePkg/BDS is the latter connects the consoles in core code while the former connects in platform code. The change initializes the console variables in PlatformBootManagerBeforeConsole() and removes the console connection code. It also removes unused functions: PlatformBdsNoConsoleAction() and LockKeyboards(). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Use ConvertDevicePathToText()Ruiyu Ni2016-05-042-3/+4
| | | | | | | | | | | | | | | | | The DevicePathToStr() function (in "IntelFrameworkModulePkg/Library/GenericBdsLib/DevicePath.c") is a simple wrapper around ConvertDevicePathToText(). DevicePathToStr() passes DisplayOnly=TRUE and AllowShortcuts=TRUE to ConvertDevicePathToText(), whereas in this patch, both parameters are flipped to FALSE. The formatted devpaths are used only for debugging purposes, so this change is safe. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: link to UefiBootManagerLibRuiyu Ni2016-05-042-2/+2
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: use EfiBootManagerUpdateConsoleVariableRuiyu Ni2016-05-041-16/+16
| | | | | | | | | | | Call EfiBootManagerUpdateConsoleVariable in UefiBootManagerLib instead of BdsLibUpdateConsoleVariable in GenericBdsLib. Still cannot pass build. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg/PlatformBootManagerLib: Follow PlatformBootManagerLib interfacesRuiyu Ni2016-05-043-27/+22
| | | | | | | | | | | | | Change the function name to follow new library class PlatformBootManagerLib interfaces. NOTE: There is no progress bar during BDS timeout waiting. In order to show the progress bar, PlatformBootManagerWaitCallback () needs to change to draw it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* OvmfPkg: Duplicate PlatformBdsLib to PlatformBootManagerLibRuiyu Ni2016-05-045-0/+2178
It will be changed to build with MdeModulePkg/BDS. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>