mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-19 00:54:41 +08:00
x86/smpboot: Restrict soft_restart_cpu() to SEV
Now that the CPU0 hotplug cruft is gone, the only user is AMD SEV. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Tested-by: Michael Kelley <mikelley@microsoft.com> Tested-by: Oleksandr Natalenko <oleksandr@natalenko.name> Tested-by: Helge Deller <deller@gmx.de> # parisc Tested-by: Guilherme G. Piccoli <gpiccoli@igalia.com> # Steam Deck Link: https://lore.kernel.org/r/20230512205255.822234014@linutronix.de
This commit is contained in:
parent
5475abbde7
commit
cded367976
@ -133,7 +133,7 @@ static bool skip_addr(void *dest)
|
||||
/* Accounts directly */
|
||||
if (dest == ret_from_fork)
|
||||
return true;
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
#if defined(CONFIG_HOTPLUG_CPU) && defined(CONFIG_AMD_MEM_ENCRYPT)
|
||||
if (dest == soft_restart_cpu)
|
||||
return true;
|
||||
#endif
|
||||
|
@ -138,20 +138,6 @@ SYM_CODE_START(startup_32)
|
||||
jmp .Ldefault_entry
|
||||
SYM_CODE_END(startup_32)
|
||||
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
/*
|
||||
* Entry point for soft restart of a CPU. Invoked from xxx_play_dead() for
|
||||
* restarting the boot CPU or for restarting SEV guest CPUs after CPU hot
|
||||
* unplug. Everything is set up already except the stack.
|
||||
*/
|
||||
SYM_FUNC_START(soft_restart_cpu)
|
||||
movl initial_stack, %ecx
|
||||
movl %ecx, %esp
|
||||
call *(initial_code)
|
||||
1: jmp 1b
|
||||
SYM_FUNC_END(soft_restart_cpu)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Non-boot CPU entry point; entered from trampoline.S
|
||||
* We can't lgdt here, because lgdt itself uses a data segment, but
|
||||
|
@ -375,7 +375,7 @@ SYM_CODE_END(secondary_startup_64)
|
||||
#include "verify_cpu.S"
|
||||
#include "sev_verify_cbit.S"
|
||||
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
#if defined(CONFIG_HOTPLUG_CPU) && defined(CONFIG_AMD_MEM_ENCRYPT)
|
||||
/*
|
||||
* Entry point for soft restart of a CPU. Invoked from xxx_play_dead() for
|
||||
* restarting the boot CPU or for restarting SEV guest CPUs after CPU hot
|
||||
|
Loading…
Reference in New Issue
Block a user