2019-05-29 11:10:01 +02:00
|
|
|
.globl _start
|
|
|
|
|
|
|
|
_start:
|
2019-05-30 08:44:01 +02:00
|
|
|
|
2019-05-29 11:10:01 +02:00
|
|
|
mrs x0, mpidr_el1 // Check CPU ID
|
|
|
|
mov x1, 0xC1000000
|
|
|
|
bic x0, x0, x1
|
|
|
|
cbz x0, set_stack
|
|
|
|
b idle
|
|
|
|
|
|
|
|
set_stack:
|
2019-05-30 08:44:01 +02:00
|
|
|
ldr x30, =stack_ptr // defined in sys/memmap
|
2019-05-29 11:10:01 +02:00
|
|
|
mov sp, x30
|
2019-05-30 08:44:01 +02:00
|
|
|
bl k_main
|
2019-05-29 11:10:01 +02:00
|
|
|
|
|
|
|
idle:
|
|
|
|
b idle
|
|
|
|
|