From 876c1d36b3d5298abea6dab404cd9bc2aeefd897 Mon Sep 17 00:00:00 2001 From: Patrick Rudolph Date: Mon, 12 Oct 2020 07:55:44 -0600 Subject: [PATCH] UefiPayloadPkg: Make TerminalDxe build time configurable As the TerminalDxe significantly slows down the boot menu rendering, disable it but default and add the option SERIAL_TERMINAL to enabled it for headless platforms. Signed-off-by: Patrick Rudolph --- UefiPayloadPkg/UefiPayloadPkg.fdf | 2 ++ UefiPayloadPkg/UefiPayloadPkgIa32.dsc | 5 +++++ UefiPayloadPkg/UefiPayloadPkgIa32X64.dsc | 5 +++++ 3 files changed, 12 insertions(+) diff --git a/UefiPayloadPkg/UefiPayloadPkg.fdf b/UefiPayloadPkg/UefiPayloadPkg.fdf index a154f0ddd9..2ea5e8f9e5 100644 --- a/UefiPayloadPkg/UefiPayloadPkg.fdf +++ b/UefiPayloadPkg/UefiPayloadPkg.fdf @@ -158,7 +158,9 @@ INF MdeModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KeyboardDxe.inf INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf +!if $(SERIAL_TERMINAL) == TRUE INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf +!endif INF UefiPayloadPkg/GraphicsOutputDxe/GraphicsOutputDxe.inf INF UefiPayloadPkg/PciPlatformDxe/PciPlatformDxe.inf diff --git a/UefiPayloadPkg/UefiPayloadPkgIa32.dsc b/UefiPayloadPkg/UefiPayloadPkgIa32.dsc index 9854d2fff0..984d076c99 100644 --- a/UefiPayloadPkg/UefiPayloadPkgIa32.dsc +++ b/UefiPayloadPkg/UefiPayloadPkgIa32.dsc @@ -64,6 +64,9 @@ DEFINE UART_DEFAULT_STOP_BITS = 1 DEFINE DEFAULT_TERMINAL_TYPE = 0 + # Enabling the serial terminal will slow down the boot menu rendering! + DEFINE SERIAL_TERMINAL = FALSE + # # typedef struct { # UINT16 VendorId; ///< Vendor ID to match the PCI device. The value 0xFFFF terminates the list of entries. @@ -561,7 +564,9 @@ MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf +!if $(SERIAL_TERMINAL) == TRUE MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf +!endif UefiPayloadPkg/GraphicsOutputDxe/GraphicsOutputDxe.inf UefiPayloadPkg/PciPlatformDxe/PciPlatformDxe.inf diff --git a/UefiPayloadPkg/UefiPayloadPkgIa32X64.dsc b/UefiPayloadPkg/UefiPayloadPkgIa32X64.dsc index 57a0390657..0a6bc85a11 100644 --- a/UefiPayloadPkg/UefiPayloadPkgIa32X64.dsc +++ b/UefiPayloadPkg/UefiPayloadPkgIa32X64.dsc @@ -64,6 +64,9 @@ DEFINE UART_DEFAULT_STOP_BITS = 1 DEFINE DEFAULT_TERMINAL_TYPE = 0 + # Enabling the serial terminal will slow down the boot menu redering! + DEFINE SERIAL_TERMINAL = FALSE + # # typedef struct { # UINT16 VendorId; ///< Vendor ID to match the PCI device. The value 0xFFFF terminates the list of entries. @@ -570,7 +573,9 @@ MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf +!if $(SERIAL_TERMINAL) == TRUE MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf +!endif UefiPayloadPkg/GraphicsOutputDxe/GraphicsOutputDxe.inf UefiPayloadPkg/PciPlatformDxe/PciPlatformDxe.inf