Extend ap_boot_mtx scope to also cover mca_init().

Otherwise, under bootverbose, the lapic_enable_cmc() banner 'lapicX:
CMCI unmasked' is printed by several CPUs in parallel, causing garbled
output for the LAPIC dumps.

Reported by:	royger
Reviewed by:	jhb
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D15157
This commit is contained in:
Konstantin Belousov 2018-04-24 20:33:08 +00:00
parent 215e4657d5
commit bc7e39c339

View File

@ -1007,10 +1007,10 @@ init_secondary_tail(void)
KASSERT(PCPU_GET(idlethread) != NULL, ("no idle thread"));
PCPU_SET(curthread, PCPU_GET(idlethread));
mca_init();
mtx_lock_spin(&ap_boot_mtx);
mca_init();
/* Init local apic for irq's */
lapic_setup(1);