HomeFreeBSD

MFC r336264, r336270-r336272, r336464, r336627: UEFI Console Improvements

Description

MFC r336264, r336270-r336272, r336464, r336627: UEFI Console Improvements

r336264:
Define ADR subtype of ACPI type for a device path.

r336270:
uefi stand: Guess the console better

For server machines, ComOut is set to the set of devices that the efi
console suppots. Parse it to see if we have serial, video or both.
Make that take precidence over the command line args. boot1.efi parses
them, but loader.efi doesn't. It's not clear where to read boot.conf
from, so we don't do that. The command line args can still be set via
efibootmgr, which is more inline with the UEFI boot manager to replace
that. These args are typically used only to set serial vs video and
the com speed line. We can infer that from ComOut, so do so.
Remember the com speed and hw.uart.console to match.

r336271:
Add reporting of whether or not a keyboard is detected. In addition,
note that r336270's commit message was slightly incorrect. It changed
the default setting of the console to honor the ConOut
variable. Overrides via the command line are still possible, and we
use the devices in ConOut to set the proper console. If, for example,
serial cosnole is specified, we'll set console to "efi" if ConOut has
a serial port list and to either "efi comconsole" or "comconsole efi"
if not depending on whether -D or -D -h was specified.

r336272:
Minor adjustments:

o Fix the parsing of the device path. a last minute change terminated

it too soon.

o Kill setting LINES. We don't need to do it, and even if we did hard

coding it to 24 is wrong.

o Now that the console is working again for the loader, adjust the

printfs to be more in line with other platforms.

r336464:
If the console is already set, don't override it.

If console=X is specified on the command line, it's effectively
overridden by the current code. It shouldn't do that.

r336627:
Fix the attempt to see if we're overriding the console in the command
line args. I had thought console would be NULL, but it's efi. Set it
to efi (as a clue) before we initialize the console, then test it to
see if it changed on the command line to do the automatic
override. This gets my serial console back.

RelNotes: yes

Details

Provenance
kevansAuthored on
Parents
rS344402: * Handle SIGPIPE in gssd
Branches
Unknown
Tags
Unknown