diff options
Diffstat (limited to 'firmware/fw_base.S')
-rw-r--r-- | firmware/fw_base.S | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/firmware/fw_base.S b/firmware/fw_base.S index 375c158..0797cc0 100644 --- a/firmware/fw_base.S +++ b/firmware/fw_base.S @@ -46,6 +46,16 @@ .globl _start .globl _start_warm _start: + /* Find preferred boot HART id */ + MOV_3R s0, a0, s1, a1, s2, a2 + call fw_boot_hart + add a6, a0, zero + MOV_3R a0, s0, a1, s1, a2, s2 + li a7, -1 + beq a6, a7, _try_lottery + /* Jump to relocation wait loop if we are not boot hart */ + bne a0, a6, _wait_relocate_copy_done +_try_lottery: /* Jump to relocation wait loop if we don't get relocation lottery */ la a6, _relocate_lottery li a7, 1 |