Attention is currently required from: Nico Huber, Wonkyu Kim, Tim Wawrzynczak. Kyösti Mälkki has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/60213 )
Change subject: cpu/x86/lapic: Fix choice X2APIC_ONLY ......................................................................
Patch Set 3:
(2 comments)
Commit Message:
https://review.coreboot.org/c/coreboot/+/60213/comment/7e5e05d9_801ccfbe PS2, Line 11: avoid entering a printk() and acquiring console_lock and : dead-locking.
I dunno, that sounds like possibly a microarchitectural detail... […]
With X2APIC it is WRMSR and Angel had some Haswell notes (errata) about lack of serialization.
File src/cpu/x86/mp_init.c:
https://review.coreboot.org/c/coreboot/+/60213/comment/634f56f2_799893b0 PS2, Line 652: lapic_send_ipi(LAPIC_INT_ASSERT | LAPIC_DM_SMI, lapicid());
Sorry let me be more clear. I mean, if a delay or fence, etc. […]
Well, there is LAPIC ICR Destination Shorthand for "ALL LAPIC" and if we ever used it, it would need the short delay too. I think there is no point to separate the case where IPI is _not_ delivered to self and the short loop is not required.
The 1000 was random choice, we know X2APIC_BOTH=y that only added few (actual) instructions like 'test, jle' also worked.