mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
x86: Do not attempt to calibrate the LAPIC timer if no APIC is present
Reported and tested by: Michael Butler <imb@protected-networks.net>
Reviewed by: jhb, kib
Fixes: 62d09b46ad ("x86: Defer LAPIC calibration until after timecounters are available")
MFC after: 3 days
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D33669
This commit is contained in:
parent
deca0138dc
commit
0ecda8d5ae
1 changed files with 6 additions and 0 deletions
|
|
@ -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()];
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue