diff options
author | li-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-09-04 09:43:22 +0000 |
---|---|---|
committer | li-elvin <li-elvin@6f19259b-4bc3-4df7-8a09-765794883524> | 2012-09-04 09:43:22 +0000 |
commit | 641b4a46284c0a3c2392b2cebea375da7542265f (patch) | |
tree | 83ae72d1d31ca034ce641de0f717980b19824363 | |
parent | 99bb0f8dd7d5aaa531ed3eec08e27c05d8f45e21 (diff) | |
download | edk2-641b4a46284c0a3c2392b2cebea375da7542265f.tar.gz edk2-641b4a46284c0a3c2392b2cebea375da7542265f.tar.bz2 edk2-641b4a46284c0a3c2392b2cebea375da7542265f.zip |
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
-rw-r--r-- | IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c b/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c index 782c4a5ce1..fe6d436a56 100644 --- a/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c +++ b/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConsole.c @@ -88,6 +88,7 @@ UpdateSystemTableConsole ( EFI_DEVICE_PATH_PROTOCOL *Instance;
VOID *Interface;
EFI_HANDLE NewHandle;
+ EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *TextOut;
ASSERT (VarName != NULL);
ASSERT (ConsoleHandle != NULL);
@@ -159,6 +160,15 @@ UpdateSystemTableConsole ( //
*ConsoleHandle = NewHandle;
*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;
}
}
|