summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoonas Lahtinen <joonas.lahtinen@linux.intel.com>2014-01-15 11:08:04 +0000
committerTom Gundersen <teg@jklm.no>2014-01-15 12:15:35 +0100
commit5dc44b39406f0c9e941389aa5d7272657c7447ae (patch)
treeb55e2dfbb8ff969b7b91403ed731b9d5995e510e
parent76edd469574a57226ee26ee46d84b7d2709fa070 (diff)
graphics: Do not require nonstandard console control protocol
Console Control Protocol is a nonstandard UEFI interface and lack of it shall not be treated as an error. Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
-rw-r--r--src/efi/graphics.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/efi/graphics.c b/src/efi/graphics.c
index 062ce27..c85daa3 100644
--- a/src/efi/graphics.c
+++ b/src/efi/graphics.c
@@ -67,8 +67,10 @@ EFI_STATUS graphics_mode(BOOLEAN on) {
EFI_STATUS err;
err = LibLocateProtocol(&ConsoleControlProtocolGuid, (VOID **)&ConsoleControl);
- if (EFI_ERROR(err))
- return err;
+ if (EFI_ERROR(err)) {
+ /* console control protocol is nonstandard and might not exist. */
+ return err == EFI_NOT_FOUND ? EFI_SUCCESS : err;
+ }
/* check current mode */
err = uefi_call_wrapper(ConsoleControl->GetMode, 4, ConsoleControl, &current, &uga_exists, &stdin_locked);