diff --git a/sys/x86/x86/local_apic.c b/sys/x86/x86/local_apic.c index 1264eeaaf7b..23b780b121e 100644 --- a/sys/x86/x86/local_apic.c +++ b/sys/x86/x86/local_apic.c @@ -913,6 +913,12 @@ native_lapic_calibrate_timer(void) struct lapic *la; register_t intr; +#ifdef DEV_ATPIC + /* Fail if the local APIC is not present. */ + if (!x2apic_mode && lapic_map == NULL) + return; +#endif + intr = intr_disable(); la = &lapics[lapic_id()];