summaryrefslogtreecommitdiff
path: root/include/linux/cpuhotplug.h
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw@amazon.co.uk>2023-05-12 23:07:43 +0200
committerPeter Zijlstra <peterz@infradead.org>2023-05-15 13:45:00 +0200
commit6d712b9b3a58018259fb40ddd498d1f7dfa1f4ec (patch)
treeb4b579e063cb36a682f4f04756dc34d01fc80e95 /include/linux/cpuhotplug.h
parentbc088f9a0d5bdf12bb18980739336dfcc092e55b (diff)
cpu/hotplug: Reset task stack state in _cpu_up()
Commit dce1ca0525bf ("sched/scs: Reset task stack state in bringup_cpu()") ensured that the shadow call stack and KASAN poisoning were removed from a CPU's stack each time that CPU is brought up, not just once. This is not incorrect. However, with parallel bringup the idle thread setup will happen at a different step. As a consequence the cleanup in bringup_cpu() would be too late. Move the SCS/KASAN cleanup to the generic _cpu_up() function instead, which already ensures that the new CPU's stack is available, purely to allow for early failure. This occurs when the CPU to be brought up is in the CPUHP_OFFLINE state, which should correctly do the cleanup any time the CPU has been taken down to the point where such is needed. Signed-off-by: David Woodhouse <dwmw@amazon.co.uk> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Tested-by: Mark Rutland <mark.rutland@arm.com> 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/20230512205257.027075560@linutronix.de
Diffstat (limited to 'include/linux/cpuhotplug.h')
0 files changed, 0 insertions, 0 deletions