summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
authorDamien Le Moal <damien.lemoal@wdc.com>2018-12-21 04:03:56 +0300
committerDamien Le Moal <damien.lemoal@wdc.com>2018-12-21 09:09:13 +0300
commit513474cd1b6f3481ee72ec71df916880d7bc0232 (patch)
treebdf1ede49ce9a7651bd43e534d6f5422733f50ec /firmware
parentaa68f0252f2a0749dee35bda309c397f79ae26a0 (diff)
downloadopensbi-513474cd1b6f3481ee72ec71df916880d7bc0232.tar.xz
Fix FDT relocation
Or rather, disable it if FW_PAYLOAD_FDT_ADDR is not defined. This correspond to cases where the underlying FW that loaded and started opensbi did not provide any FDT. In such case, the platform code will need to prepare one. Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Diffstat (limited to 'firmware')
-rw-r--r--firmware/fw_common.S2
1 files changed, 2 insertions, 0 deletions
diff --git a/firmware/fw_common.S b/firmware/fw_common.S
index a2685cf..9963fdd 100644
--- a/firmware/fw_common.S
+++ b/firmware/fw_common.S
@@ -41,6 +41,7 @@ _bss_zero:
add a1, t1, zero
_prev_arg1_override_done:
+#ifdef FW_PAYLOAD_FDT_ADDR
/*
* Relocate Flatened Device Tree (FDT)
* source FDT address = previous arg1
@@ -99,6 +100,7 @@ _fdt_reloc_again:
add t1, t1, __SIZEOF_POINTER__
blt t1, t2, _fdt_reloc_again
_fdt_reloc_done:
+#endif
/* Update boot hart flag */
la a4, _boot_hart_done