#include "power/shutdown.h" #include "io/IO.h" #include "log/Log.h" #include "panic/hang.h" [[noreturn]] void shutdown() { kinfoln("Attempting shutdown using the Bochs method"); IO::outw(0xB004, 0x2000); kinfoln("Attempting shutdown using the QEMU method"); IO::outw(0x604, 0x2000); kinfoln("Attempting shutdown using the VirtualBox method"); IO::outw(0x4004, 0x3400); kerrorln("Failed to shutdown, halting. It is now safe to turn off your computer manually, though."); hang(); }