1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-30 22:28:12 +00:00

Kernel: Allow to reboot in ACPI via PCI or MMIO access

Also, we determine if ACPI reboot is supported by checking the FADT
flags' field.
This commit is contained in:
Liav A 2020-03-08 16:50:46 +02:00 committed by Andreas Kling
parent 8639ee2640
commit 0f45a1b5e7
9 changed files with 183 additions and 25 deletions

View file

@ -4007,10 +4007,8 @@ int Process::sys$reboot()
FS::lock_all();
dbg() << "syncing mounted filesystems...";
FS::sync();
if (ACPI::Parser::the().can_reboot()) {
dbg() << "attempting reboot via ACPI";
ACPI::Parser::the().try_acpi_reboot();
}
dbg() << "attempting reboot via ACPI";
ACPI::Parser::the().try_acpi_reboot();
dbg() << "attempting reboot via KB Controller...";
IO::out8(0x64, 0xFE);