summaryrefslogtreecommitdiffstats
path: root/cpukit/score/cpu/aarch64/cpu_asm.S
diff options
context:
space:
mode:
Diffstat (limited to 'cpukit/score/cpu/aarch64/cpu_asm.S')
-rw-r--r--cpukit/score/cpu/aarch64/cpu_asm.S17
1 files changed, 17 insertions, 0 deletions
diff --git a/cpukit/score/cpu/aarch64/cpu_asm.S b/cpukit/score/cpu/aarch64/cpu_asm.S
index 2379698336..6321acde90 100644
--- a/cpukit/score/cpu/aarch64/cpu_asm.S
+++ b/cpukit/score/cpu/aarch64/cpu_asm.S
@@ -203,4 +203,21 @@ DEFINE_FUNCTION_AARCH64(_CPU_Context_restore)
#endif
b .L_check_is_executing
+
+DEFINE_FUNCTION_AARCH64(_AArch64_Start_multitasking)
+#ifdef AARCH64_MULTILIB_ARCH_V8_ILP32
+ /* Sanitize input for ILP32 ABI */
+ mov w0, w0
+#endif
+
+ mov x1, x0
+ GET_SELF_CPU_CONTROL reg_2
+
+ /* Switch the stack to the temporary interrupt stack of this processor */
+ add sp, x2, #(PER_CPU_INTERRUPT_FRAME_AREA + CPU_INTERRUPT_FRAME_SIZE)
+
+ /* Enable interrupts */
+ msr DAIFClr, #0x2
+
+ b .L_check_is_executing
#endif