summaryrefslogtreecommitdiff
path: root/src/cpu
diff options
context:
space:
mode:
authorArthur Heymans <arthur@aheymans.xyz>2021-03-02 12:29:16 +0100
committerPatrick Georgi <pgeorgi@google.com>2021-03-19 11:33:43 +0000
commit41b078f8aecd9d01b83ac8ceb646645b8d1c4722 (patch)
treee35233875e2c3a907b050ac8b679ab2d9da2833a /src/cpu
parent1e1d5d60f72efa006dad18cab9f49f381d79cd9b (diff)
cpu/x86/mp_init.c: Don't overwrite the global variable per CPU
Global variables are located in .bss and not on the CPU stack. Overwriting them a per CPU case is bound to cause race conditions. In this case it is even just plainly wrong. Note: This variable is set up in the get_smm_info() function. Change-Id: Iaef26fa996f7e30b6e4c4941683026b8a29a5fd1 Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/51184 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src/cpu')
-rw-r--r--src/cpu/x86/mp_init.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/cpu/x86/mp_init.c b/src/cpu/x86/mp_init.c
index 1acb22819a..a545d67537 100644
--- a/src/cpu/x86/mp_init.c
+++ b/src/cpu/x86/mp_init.c
@@ -732,7 +732,6 @@ static void asmlinkage smm_do_relocation(void *arg)
*/
#if CONFIG(X86_SMM_LOADER_VERSION2)
perm_smbase = smm_get_cpu_smbase(cpu);
- mp_state.perm_smbase = perm_smbase;
if (!perm_smbase) {
printk(BIOS_ERR, "%s: bad SMBASE for CPU %d\n", __func__, cpu);
return;