mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 19:29:16 +00:00
Kernel: Add option to force using only the bootloader framebuffer
This allows forcing the use of only the framebuffer set up by the bootloader and skips instantiating devices for any other graphics cards that may be present.
This commit is contained in:
@@ -245,9 +245,14 @@ PanicMode CommandLine::panic_mode(Validate should_validate) const
|
||||
return PanicMode::Halt;
|
||||
}
|
||||
|
||||
UNMAP_AFTER_INIT bool CommandLine::are_framebuffer_devices_enabled() const
|
||||
UNMAP_AFTER_INIT auto CommandLine::are_framebuffer_devices_enabled() const -> FrameBufferDevices
|
||||
{
|
||||
return lookup("fbdev"sv).value_or("on"sv) == "on"sv;
|
||||
const auto fbdev_value = lookup("fbdev"sv).value_or("on"sv);
|
||||
if (fbdev_value == "on"sv)
|
||||
return FrameBufferDevices::Enabled;
|
||||
if (fbdev_value == "bootloader"sv)
|
||||
return FrameBufferDevices::BootloaderOnly;
|
||||
return FrameBufferDevices::ConsoleOnly;
|
||||
}
|
||||
|
||||
StringView CommandLine::userspace_init() const
|
||||
|
||||
Reference in New Issue
Block a user