mirror of
https://github.com/RGBCube/serenity
synced 2025-05-28 22:15:07 +00:00
Kernel: Move Kernel CommandLine parsing to strongly typed API.
Previously all of the CommandLine parsing was spread out around the Kernel. Instead move it all into the Kernel CommandLine class, and expose a strongly typed API for querying the state of options.
This commit is contained in:
parent
74881ac649
commit
84a399de5d
9 changed files with 143 additions and 45 deletions
|
@ -50,7 +50,7 @@ UNMAP_AFTER_INIT static Access::Type detect_optimal_access_type(bool mmio_allowe
|
|||
|
||||
UNMAP_AFTER_INIT void initialize()
|
||||
{
|
||||
bool mmio_allowed = kernel_command_line().lookup("pci_mmio").value_or("off") == "on";
|
||||
bool mmio_allowed = kernel_command_line().is_mmio_enabled();
|
||||
|
||||
if (detect_optimal_access_type(mmio_allowed) == Access::Type::MMIO)
|
||||
MMIOAccess::initialize(ACPI::Parser::the()->find_table("MCFG"));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue