mirror of https://github.com/acidanthera/audk.git
Set mode 0 (80x25) when Consplitter does not exist.
Signed-off-by: Li Elvin <elvin.li@intel.com> Reviewed-by: Ni Ruiyu <ruiyu.ni@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13698 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
99bb0f8dd7
commit
641b4a4628
|
@ -88,6 +88,7 @@ UpdateSystemTableConsole (
|
||||||
EFI_DEVICE_PATH_PROTOCOL *Instance;
|
EFI_DEVICE_PATH_PROTOCOL *Instance;
|
||||||
VOID *Interface;
|
VOID *Interface;
|
||||||
EFI_HANDLE NewHandle;
|
EFI_HANDLE NewHandle;
|
||||||
|
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut;
|
||||||
|
|
||||||
ASSERT (VarName != NULL);
|
ASSERT (VarName != NULL);
|
||||||
ASSERT (ConsoleHandle != NULL);
|
ASSERT (ConsoleHandle != NULL);
|
||||||
|
@ -159,6 +160,15 @@ UpdateSystemTableConsole (
|
||||||
//
|
//
|
||||||
*ConsoleHandle = NewHandle;
|
*ConsoleHandle = NewHandle;
|
||||||
*ProtocolInterface = Interface;
|
*ProtocolInterface = Interface;
|
||||||
|
if (CompareGuid (ConsoleGuid, &gEfiSimpleTextOutProtocolGuid)) {
|
||||||
|
//
|
||||||
|
// If it is console out device, set console mode 80x25 if current mode is invalid.
|
||||||
|
//
|
||||||
|
TextOut = (EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *) Interface;
|
||||||
|
if (TextOut->Mode->Mode == -1) {
|
||||||
|
TextOut->SetMode (TextOut, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue