summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorPeter Jones <pjones@redhat.com>2018-04-05 13:50:18 -0400
committerPeter Jones <pjones@redhat.com>2018-04-05 14:49:17 -0400
commit41be16891924eb7db6e5a3d994f8405f3e64ab2e (patch)
treed0ae97c46261d1f7aca6bcd4d3c4e84a269113d5 /lib
parent510474e72d1a333f1db40853a8aa67186ea39849 (diff)
downloadefi-boot-shim-41be16891924eb7db6e5a3d994f8405f3e64ab2e.tar.gz
efi-boot-shim-41be16891924eb7db6e5a3d994f8405f3e64ab2e.zip
Make setup_console(-1) do GetMode() and call it from setup_verbosity()
Signed-off-by: Peter Jones <pjones@redhat.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/console.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/console.c b/lib/console.c
index 3d28daaf..12f48b08 100644
--- a/lib/console.c
+++ b/lib/console.c
@@ -68,6 +68,13 @@ static VOID setup_console (int text)
/* If that didn't work, assume it's graphics */
if (EFI_ERROR(efi_status))
mode = EfiConsoleControlScreenGraphics;
+ if (text < 0) {
+ if (mode == EfiConsoleControlScreenGraphics)
+ console_text_mode = 0;
+ else
+ console_text_mode = 1;
+ return;
+ }
} else {
new_mode = mode;
}
@@ -510,6 +517,8 @@ setup_verbosity(VOID)
verbose = 0;
if (!EFI_ERROR(efi_status))
verbose = verbose_check;
+
+ setup_console(-1);
}
/* Included here because they mess up the definition of va_list and friends */