freebsd-dev/sys/x86
Andriy Gapon 7c5ccd2dce calibrate lapic timer in native_lapic_setup
The idea is to calibrate the LAPIC timer just once and only on boot,
given that [at present] the timer constants are global and shared
between all processors.

My primary motivation is to fix a panic that can happen when dynamically
switching to lapic timer.  The panic is caused by a recursion on
et_hw_mtx when printing the calibration results to console.  See the
review for the details of the panic.

Also, the code should become slightly simpler and easier to read.  The
previous code was racy too.  Multiple processors could start calibrating
the global constants concurrently, although that seems to have been
benign.

Reviewed by:	kib, mav, jhb
MFC after:	3 weeks
Differential Revision: https://reviews.freebsd.org/D15422
2018-05-15 16:56:30 +00:00
..
acpica Redo r332918 with the ACPICA API and remove debug.acpi.suspend_deep_bounce. 2018-05-03 19:00:50 +00:00
bios sys/x86: further adoption of SPDX licensing ID tags. 2017-11-27 15:11:47 +00:00
cpufreq cpufreq: Remove error-prone table terminators in favor of automatic sizing 2018-04-14 03:15:05 +00:00
include Add helper macros to hide some boring repeatable ceremonies to define 2018-05-03 21:45:59 +00:00
iommu Don't include DMAR map entry zone items in kernel dumps. 2018-02-18 16:03:50 +00:00
isa ANSIfy sys/x86 2018-03-17 01:40:09 +00:00
pci Add ISA PNP tables to ISA drivers. Fix a few incidental comments. 2018-01-29 00:22:30 +00:00
x86 calibrate lapic timer in native_lapic_setup 2018-05-15 16:56:30 +00:00
xen xen: fix formatting of xen_init_ops 2018-05-02 10:20:55 +00:00