summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
authorLiu Yibin <yibin_liu@c-sky.com>2019-12-26 12:38:55 +0300
committerAnup Patel <anup@brainfault.org>2019-12-27 06:18:17 +0300
commitc7d1b12199a11f8dcccb631a742eb31c79f8d0d2 (patch)
tree1bc904d0d3e2b73a5acd314d577d2061d91a2a08 /firmware
parent86a31f54371c56f0ca94a8d9dfcec05a76dfa53c (diff)
downloadopensbi-c7d1b12199a11f8dcccb631a742eb31c79f8d0d2.tar.xz
firmware: Return real DTB address when FW_xyz_FDT_ADDR is not defined
Function fw_next_arg1 in firmware/fw_jump.S:59 and firmware/fw_payload.S:63 should return real dtb address(if specified in a1) in a0, in case we don't want to specify FW_xyz_FDT_ADDR when compiling. Signed-off-by: Liu Yibin <yibin_liu@c-sky.com> Reviewed-by: Anup Patel <anup.patel@wdc.com>
Diffstat (limited to 'firmware')
-rw-r--r--firmware/fw_jump.S2
-rw-r--r--firmware/fw_payload.S2
2 files changed, 2 insertions, 2 deletions
diff --git a/firmware/fw_jump.S b/firmware/fw_jump.S
index 84391c9..0015a80 100644
--- a/firmware/fw_jump.S
+++ b/firmware/fw_jump.S
@@ -56,7 +56,7 @@ fw_next_arg1:
#ifdef FW_JUMP_FDT_ADDR
li a0, FW_JUMP_FDT_ADDR
#else
- add a0, zero, zero
+ add a0, a1, zero
#endif
ret
diff --git a/firmware/fw_payload.S b/firmware/fw_payload.S
index 9f4e0ec..b9cb151 100644
--- a/firmware/fw_payload.S
+++ b/firmware/fw_payload.S
@@ -60,7 +60,7 @@ fw_next_arg1:
#ifdef FW_PAYLOAD_FDT_ADDR
li a0, FW_PAYLOAD_FDT_ADDR
#else
- add a0, zero, zero
+ add a0, a1, zero
#endif
ret