From d694b88a629c0af390ebf0b597d9514de0b7c80f Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Tue, 9 Jul 2024 14:59:30 -0400 Subject: [PATCH] kernel/x86: Make acpi_read & acpi_write private (static). They aren't used anywhere outside this file anymore, and they shouldn't be used when X2APIC is enabled, anyway. --- headers/private/kernel/arch/x86/apic.h | 2 -- src/system/kernel/arch/x86/apic.cpp | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/headers/private/kernel/arch/x86/apic.h b/headers/private/kernel/arch/x86/apic.h index a9dbed7852..23605e6c8c 100644 --- a/headers/private/kernel/arch/x86/apic.h +++ b/headers/private/kernel/arch/x86/apic.h @@ -111,8 +111,6 @@ bool apic_available(); bool x2apic_available(); -uint32 apic_read(uint32 offset); -void apic_write(uint32 offset, uint32 data); uint32 apic_local_id(); uint32 apic_local_version(); uint32 apic_task_priority(); diff --git a/src/system/kernel/arch/x86/apic.cpp b/src/system/kernel/arch/x86/apic.cpp index d8d5559f36..2226519915 100644 --- a/src/system/kernel/arch/x86/apic.cpp +++ b/src/system/kernel/arch/x86/apic.cpp @@ -39,14 +39,14 @@ x2apic_available() } -uint32 +static uint32 apic_read(uint32 offset) { return *(volatile uint32 *)((char *)sLocalAPIC + offset); } -void +static void apic_write(uint32 offset, uint32 data) { *(volatile uint32 *)((char *)sLocalAPIC + offset) = data;