diff options
author | sigsegv7 <ian@vegaa.systems> | 2023-10-04 14:47:49 -0400 |
---|---|---|
committer | sigsegv7 <ian@vegaa.systems> | 2023-10-04 14:47:49 -0400 |
commit | ecc1a2b02f7b827b71e48a3c885db508e8b84e6c (patch) | |
tree | 5bd292baffd74e01ee40e23acfd3a9066668c7e9 /sys/arch/amd64 | |
parent | 8251c86b098623607a945f70721039528073b82b (diff) |
kernel/amd64: Fix up BSP_KINFO logic
Signed-off-by: sigsegv7 <ian@vegaa.systems>
Diffstat (limited to 'sys/arch/amd64')
-rw-r--r-- | sys/arch/amd64/lapic.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/sys/arch/amd64/lapic.c b/sys/arch/amd64/lapic.c index c020f19..b3809dd 100644 --- a/sys/arch/amd64/lapic.c +++ b/sys/arch/amd64/lapic.c @@ -38,16 +38,20 @@ #include <sys/mmio.h> #include <dev/timer/hpet.h> +__naked void +__lapic_timer_isr(void); + /* * Only calls KINFO if we are the BSP. */ -#define BSP_KINFO(...) \ - uint64_t msr_val; \ - \ - msr_val = rdmsr(IA32_APIC_BASE_MSR); \ - if (__TEST(msr_val, 1 << 8)) { \ - KINFO(__VA_ARGS__); \ - } +#define BSP_KINFO(...) do { \ + uint64_t msr_val; \ + \ + msr_val = rdmsr(IA32_APIC_BASE_MSR); \ + if (__TEST(msr_val, 1 << 8)) { \ + KINFO(__VA_ARGS__); \ + } \ + } while (0); __MODULE_NAME("lapic"); __KERNEL_META("$Vega$: lapic.c, Ian Marco Moffett, " |