arch: arm64: Add stack coloration for SMP

Summary:
- This commit adds stack coloration for SMP

Impact:
- None

Testing:
- Tested with qemu-a53:nsh_smp

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
This commit is contained in:
Masayuki Ishikawa 2022-07-15 13:16:04 +09:00 committed by Xiang Xiao
parent 3682bcd4b3
commit 82cd9b0a4a
1 changed files with 9 additions and 0 deletions

View File

@ -212,6 +212,15 @@ int up_cpu_start(int cpu)
sched_note_cpu_start(this_task(), cpu);
#endif
#ifdef CONFIG_STACK_COLORATION
/* If stack debug is enabled, then fill the stack with a
* recognizable value that we can use later to test for high
* water marks.
*/
arm64_stack_color(g_cpu_idlestackalloc[cpu], SMP_STACK_SIZE);
#endif
cpu_ready_flag = 0;
arm64_start_cpu(cpu, (char *)g_cpu_idlestackalloc[cpu], SMP_STACK_SIZE,
arm64_smp_init_top);