ARM: smp: Enable THREAD_INFO_IN_TASK
authorArd Biesheuvel <ardb@kernel.org>
Sat, 18 Sep 2021 08:44:38 +0000 (10:44 +0200)
committerArd Biesheuvel <ardb@kernel.org>
Mon, 27 Sep 2021 14:54:02 +0000 (16:54 +0200)
commit18ed1c01a7dd3d7c780b06a49124da237a4c1790
tree5145998327a1a3a6e48a9432a9846b2ba73f8848
parent50596b7559bf226bb35ad55855ee979453ec06a1
ARM: smp: Enable THREAD_INFO_IN_TASK

Now that we no longer rely on thread_info living at the base of the task
stack to be able to access the 'current' pointer, we can wire up the
generic support for moving thread_info into the task struct itself.

Note that this requires us to update the cpu field in thread_info
explicitly, now that the core code no longer does so. Ideally, we would
switch the percpu code to access the cpu field in task_struct instead,
but this unleashes #include circular dependency hell.

Co-developed-by: Keith Packard <keithpac@amazon.com>
Signed-off-by: Keith Packard <keithpac@amazon.com>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Tested-by: Amit Daniel Kachhap <amit.kachhap@arm.com>
arch/arm/Kconfig
arch/arm/include/asm/assembler.h
arch/arm/include/asm/switch_to.h
arch/arm/include/asm/thread_info.h
arch/arm/kernel/asm-offsets.c
arch/arm/kernel/entry-armv.S
arch/arm/kernel/smp.c