summaryrefslogtreecommitdiff
path: root/src/cpu
diff options
context:
space:
mode:
authorPatrick Rudolph <patrick.rudolph@9elements.com>2021-01-11 09:35:49 +0100
committerPatrick Georgi <pgeorgi@google.com>2021-01-15 11:20:52 +0000
commit393992f31dc612b7e07b0ec61d83fc5589726ca1 (patch)
treea202c864ac30493cefebe0eb97a17d944c20507e /src/cpu
parentce51b34186b6eb7356c1bab752dcaccc66d96ab2 (diff)
downloadcoreboot-393992f31dc612b7e07b0ec61d83fc5589726ca1.tar.xz
cpu/mp_init: Fix microcode lock
Fix C code to match comment and assembly implementation. Tested on Prodrive hermes: The microcode spinlock is no longer used. Change-Id: I21441299f538783551d4d5ba2b2e7567e152d718 Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/49304 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/cpu')
-rw-r--r--src/cpu/x86/mp_init.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cpu/x86/mp_init.c b/src/cpu/x86/mp_init.c
index 01c1d5fb83..c691c4882b 100644
--- a/src/cpu/x86/mp_init.c
+++ b/src/cpu/x86/mp_init.c
@@ -344,9 +344,9 @@ static atomic_t *load_sipi_vector(struct mp_params *mp_params)
sp->microcode_ptr = (uintptr_t)mp_params->microcode_pointer;
/* Pass on ability to load microcode in parallel. */
if (mp_params->parallel_microcode_load)
- sp->microcode_lock = 0;
- else
sp->microcode_lock = ~0;
+ else
+ sp->microcode_lock = 0;
sp->c_handler = (uintptr_t)&ap_init;
ap_count = &sp->ap_count;
atomic_set(ap_count, 0);