1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-03 07:58:12 +00:00
serenity/Kernel/Arch/aarch64/PowerState.cpp
Liav A 9b8b8c0e04 Kernel: Simplify reboot & poweroff code flow a bit
Instead of using ifdefs to use the correct platform-specific methods, we
can just use the same pattern we use for the microseconds_delay function
which has specific implementations for each Arch CPU subdirectory.

When linking a kernel image, the actual correct and platform-specific
power-state changing methods will be called in Firmware/PowerState.cpp
file.
2023-06-27 20:04:42 +02:00

21 lines
324 B
C++

/*
* Copyright (c) 2023, Liav A. <liavalb@hotmail.co.il>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <Kernel/Arch/PowerState.h>
#include <Kernel/Arch/aarch64/RPi/Watchdog.h>
namespace Kernel {
void arch_specific_reboot()
{
}
void arch_specific_poweroff()
{
RPi::Watchdog::the().system_shutdown();
}
}