From ffdbc6e598e1b9e39b739b842a20f3b9586fe95a Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 29 Dec 2022 05:03:59 +0200 Subject: [PATCH] Call BeforeShutdown before shutting down --- Architecture/amd64/DifferentiatedSystemDescriptionTable.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Architecture/amd64/DifferentiatedSystemDescriptionTable.cpp b/Architecture/amd64/DifferentiatedSystemDescriptionTable.cpp index 4c0b102..d8dcdb1 100644 --- a/Architecture/amd64/DifferentiatedSystemDescriptionTable.cpp +++ b/Architecture/amd64/DifferentiatedSystemDescriptionTable.cpp @@ -6,6 +6,7 @@ #include #include "cpu/apic.hpp" +#include "../../kernel.h" #define ACPI_TIMER 0x0001 #define ACPI_BUSMASTER 0x0010 @@ -60,6 +61,7 @@ namespace ACPI } else if (Event & ACPI_POWER_BUTTON) { + BeforeShutdown(); this->Shutdown(); Time::Clock tm = Time::ReadClock(); while (tm.Second == Time::ReadClock().Second)