diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2022-03-08 16:56:49 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2022-03-09 21:11:10 +0100 |
commit | 32f0f11a68d3aa521f0398c9b8eec3d47f114c5e (patch) | |
tree | 672d1bd028d0e8c625dbe75db318050528f7c4b4 /cpukit/score/cpu/aarch64/include/rtems/score/cpu.h | |
parent | bsp/altera-cyclone-v: fix the creation of reserved memory regions (diff) | |
download | rtems-32f0f11a68d3aa521f0398c9b8eec3d47f114c5e.tar.bz2 |
SMP: Fix start multitasking for some targets
The previous SMP multitasking start assumed that the initial heir thread of a
processor starts execution in _Thread_Handler(). The _Thread_Handler() sets
the interrupt state explicitly by _ISR_Set_level() before it calls the thread
entry. Under certain timing conditions, processors may perform an initial
context switch to a thread which already executes its thread body (see
smptests/smpstart01). In this case, interrupts are disabled after the context
switch on targets which do not save/restore the interrupt state during a
context switch (aarch64, arm, and riscv).
Close #4627.
Diffstat (limited to 'cpukit/score/cpu/aarch64/include/rtems/score/cpu.h')
-rw-r--r-- | cpukit/score/cpu/aarch64/include/rtems/score/cpu.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cpukit/score/cpu/aarch64/include/rtems/score/cpu.h b/cpukit/score/cpu/aarch64/include/rtems/score/cpu.h index e1d9f0a5c2..fdc0e3d929 100644 --- a/cpukit/score/cpu/aarch64/include/rtems/score/cpu.h +++ b/cpukit/score/cpu/aarch64/include/rtems/score/cpu.h @@ -285,6 +285,10 @@ void _CPU_Context_Initialize( { context->is_executing = is_executing; } + + RTEMS_NO_RETURN void _AArch64_Start_multitasking( Context_Control *heir ); + + #define _CPU_Start_multitasking( _heir ) _AArch64_Start_multitasking( _heir ) #endif #define _CPU_Context_Restart_self( _the_context ) \ |