From f12a4ff14442016a3fd2e2bcd43ccefc9ea2e8bb Mon Sep 17 00:00:00 2001 From: Jeremy Soller <jeremy@system76.com> Date: Thu, 10 Feb 2022 20:35:18 -0700 Subject: [PATCH] Fall back to current EFI GOP resolution --- src/os/uefi/arch/x86_64/mod.rs | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/os/uefi/arch/x86_64/mod.rs b/src/os/uefi/arch/x86_64/mod.rs index 1b3f69a..3dab3c6 100644 --- a/src/os/uefi/arch/x86_64/mod.rs +++ b/src/os/uefi/arch/x86_64/mod.rs @@ -219,7 +219,20 @@ impl Os< }, Err(err) => { log::warn!("Failed to get EFI EDID: {:?}", err); - None + + // Fallback to the current output resolution + match Output::one() { + Ok(output) => { + Some(( + output.0.Mode.Info.HorizontalResolution, + output.0.Mode.Info.VerticalResolution, + )) + }, + Err(err) => { + log::error!("Failed to get output: {:?}", err); + None + } + } } } } -- GitLab