[Bug 265980] memstick image defaults to serial console on Asus PRIME Z690-P D4 / i7-12700 system - EFI FW has no ConOut

From: <bugzilla-noreply_at_freebsd.org>
Date: Sun, 21 Aug 2022 23:04:57 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=265980

--- Comment #8 from Ed Maste <emaste@freebsd.org> ---
Related commit:

commit 14fb9485a4dc9c8212bfae6c2049cb4930f4b8e5
Author: Emmanuel Vadot <manu@FreeBSD.org>
Date:   Fri Nov 8 20:08:44 2019 +0000

    loader.efi: Default to serial if we don't have a ConOut variable

    In the EFI implementation in U-Boot no ConOut efi variable is created,
    this cause loader to fallback to TERM_EMU implementation which is very
    very very slow (and uses the ConOut device in the system table anyway).
    The UEFI spec aren't clear as if this variable needs to exists or not.

    Reviewed by:    imp, kevans

Notes:
    svn path=/head/; revision=354559

diff --git a/stand/efi/loader/main.c b/stand/efi/loader/main.c
index c5d664dce65e..641cc7154f13 100644
--- a/stand/efi/loader/main.c
+++ b/stand/efi/loader/main.c
@@ -703,8 +703,11 @@ parse_uefi_con_out(void)
        how = 0;
        sz = sizeof(buf);
        rv = efi_global_getenv("ConOut", buf, &sz);
-       if (rv != EFI_SUCCESS)
+       if (rv != EFI_SUCCESS) {
+               /* If we don't have any ConOut default to serial */
+               how = RB_SERIAL;
                goto out;
+       }
        ep = buf + sz;
        node = (EFI_DEVICE_PATH *)buf;
        while ((char *)node < ep) {

-- 
You are receiving this mail because:
You are the assignee for the bug.