From d1a034b08d1be32d447560ac17762d13db147bea Mon Sep 17 00:00:00 2001 From: lukileczo Date: Thu, 17 Aug 2023 10:09:41 +0200 Subject: [PATCH] riscv64: load args to main in _start JIRA: RTOS-559 --- arch/riscv64/_start.S | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/arch/riscv64/_start.S b/arch/riscv64/_start.S index 41a981a2..3e2b6c4f 100644 --- a/arch/riscv64/_start.S +++ b/arch/riscv64/_start.S @@ -25,7 +25,10 @@ _start: .option norelax la gp, __global_pointer$ .option pop - + ld ra, (sp) + ld a0, 8(sp) + ld a1, 16(sp) + ld a2, 24(sp) + addi sp, sp, 32 j _startc - .size _start, .-_start