From 08e69a55cfda4722277d16ddb632669edde3580b Mon Sep 17 00:00:00 2001 From: Amlal Date: Wed, 23 Oct 2024 10:08:05 +0200 Subject: IMP: Process scheduler timer interrupt have been implemented, fixes regarding interrupt API and use __TOOLCHAINKIT__ instead of __NDK__ Signed-off-by: Amlal --- dev/zka/src/ACPIFactoryInterface.cc | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'dev/zka/src/ACPIFactoryInterface.cc') diff --git a/dev/zka/src/ACPIFactoryInterface.cc b/dev/zka/src/ACPIFactoryInterface.cc index c7d2914f..230b6ed6 100644 --- a/dev/zka/src/ACPIFactoryInterface.cc +++ b/dev/zka/src/ACPIFactoryInterface.cc @@ -29,11 +29,11 @@ namespace Kernel RSDT* xsdt = reinterpret_cast(rsp_ptr->RsdtAddress); - Int64 num = (xsdt->Length - sizeof(SDT)) / sizeof(UInt32); + Int64 num = (xsdt->Length - sizeof(SDT)) / sizeof(Int64); /*** - crucial to avoid - overflows. - */ + crucial to avoid underflows. + */ if (num < 1) { /// stop here, we should have entries... @@ -64,7 +64,8 @@ namespace Kernel if (signature_index == (cAcpiSignatureLength - 1)) { - kcout << "ACPI: Found the SDT" << endl; + kcout << "ACPI: SDT Signature: " << sdt->Signature << endl; + kcout << "ACPI: SDT OEM ID: " << sdt->OemId << endl; return ErrorOr(reinterpret_cast(xsdt->AddressArr[index])); } } @@ -74,10 +75,10 @@ namespace Kernel } /*** - @brief check SDT header + @brief Checksum on SDT header. @param checksum the header to checksum @param len the length of it. -*/ + */ bool ACPIFactoryInterface::Checksum(const Char* checksum, SSizeT len) { if (len == 0) -- cgit v1.2.3