summaryrefslogtreecommitdiffstats
path: root/arch/arm/include
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2021-10-05 09:15:40 +0200
committerArd Biesheuvel <ardb@kernel.org>2021-12-03 15:11:31 +0100
commitd4664b6c987f80338407889c1e3f3abe7e16be94 (patch)
tree21565f50f64551f10a68d2df793711ac07962c53 /arch/arm/include
parenteae9523fdd7a6c592e80666681962acbd913cda2 (diff)
downloadlinux-stable-d4664b6c987f80338407889c1e3f3abe7e16be94.tar.gz
linux-stable-d4664b6c987f80338407889c1e3f3abe7e16be94.tar.bz2
linux-stable-d4664b6c987f80338407889c1e3f3abe7e16be94.zip
ARM: implement IRQ stacks
Now that we no longer rely on the stack pointer to access the current task struct or thread info, we can implement support for IRQ stacks cleanly as well. Define a per-CPU IRQ stack and switch to this stack when taking an IRQ, provided that we were not already using that stack in the interrupted context. This is never the case for IRQs taken from user space, but ones taken while running in the kernel could fire while one taken from user space has not completed yet. Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Acked-by: Linus Walleij <linus.walleij@linaro.org> Tested-by: Keith Packard <keithpac@amazon.com> Acked-by: Nick Desaulniers <ndesaulniers@google.com> Tested-by: Marc Zyngier <maz@kernel.org> Tested-by: Vladimir Murzin <vladimir.murzin@arm.com> # ARMv7M
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/assembler.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/include/asm/assembler.h b/arch/arm/include/asm/assembler.h
index 870bfaea4318..1b9d4df331aa 100644
--- a/arch/arm/include/asm/assembler.h
+++ b/arch/arm/include/asm/assembler.h
@@ -86,6 +86,10 @@
#define IMM12_MASK 0xfff
+/* the frame pointer used for stack unwinding */
+ARM( fpreg .req r11 )
+THUMB( fpreg .req r7 )
+
/*
* Enable and disable interrupts
*/