On Wed, Jun 04, 2025 at 01:27:39PM +0000, Emmanuel Dreyfus wrote: > On Wed, Jun 04, 2025 at 09:05:36AM -0400, Thor Lancelot Simon wrote: > > Can (and should) we access the console via EFI interfaces in this case? > > You can skip the call to UEFI ExitBootServices() but I guess you need > to take care of not overwriting memory used by UEFI. I recall doing > that to get console output later during kernel load process. It worked, > but I did not try to call UEFI Read/Write from the kernel.
It seems to me that -- ideally -- we wouldn't ExitBootServices until we had finished probe and attach of all devices needed to get the system to single-user mode. But maybe the console is the only one that's really in that category, the way our current boot process works even if netbooting. I suppose it's a worthwhile question whether the probe/attach for a USB serial console will actually work properly if we haven't called ExitBootServices, but I'd hope the answer is that it's sufficient to do immediately _afterwards_. Thor