From 0ba891c1b044d74656a6aa5a7d57e82a92bd2725 Mon Sep 17 00:00:00 2001 From: Oki Minabe Date: Tue, 3 May 2022 17:29:50 +0900 Subject: [PATCH] armv7-a: smp: fix stack coloration Summary: - The stack pointer is subtracted to alloc xcptcontext area in the __cpu?_start block - Fix the stack coloration overrun to the previous cpu's xcpt area Impact: - armv7-a's smp configuration Testing: - smp and ostest on sabre-6quad:smp w/ qemu Signed-off-by: Oki Minabe --- arch/arm/src/armv7-a/arm_cpuhead.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/src/armv7-a/arm_cpuhead.S b/arch/arm/src/armv7-a/arm_cpuhead.S index 58e72247659..9d71005a769 100644 --- a/arch/arm/src/armv7-a/arm_cpuhead.S +++ b/arch/arm/src/armv7-a/arm_cpuhead.S @@ -441,7 +441,7 @@ __cpu3_start: #ifdef CONFIG_STACK_COLORATION .type .Lstkinit, %object .Lstkinit: - .long SMP_STACK_WORDS + .long SMP_STACK_WORDS - (XCPTCONTEXT_SIZE / 4) .long STACK_COLOR /* Stack coloration word */ .size .Lstkinit, . -.Lstkinit #endif