summaryrefslogtreecommitdiff
path: root/arch/riscv
diff options
context:
space:
mode:
authorAtish Patra <atish.patra@wdc.com>2020-04-21 11:15:02 -0700
committerAndes <uboot@andestech.com>2020-04-23 10:14:16 +0800
commit0cb27856d12ff1350996f93015972203b24387cc (patch)
tree88dcb301539b8b2b3141de73901da8f263ed5b43 /arch/riscv
parentd4ea649f179a69edd2cf2dd96efb9337205eb015 (diff)
downloadu-boot-0cb27856d12ff1350996f93015972203b24387cc.tar.gz
u-boot-0cb27856d12ff1350996f93015972203b24387cc.tar.bz2
u-boot-0cb27856d12ff1350996f93015972203b24387cc.zip
riscv: Setup reserved-memory node for FU540
FU540 uses OF_SEPARATE instead of OF_PRIOR_STAGE. Enable OF_BOARD_FIXUP to update the DT with reserved-memory node. Signed-off-by: Atish Patra <atish.patra@wdc.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'arch/riscv')
-rw-r--r--arch/riscv/lib/fdt_fixup.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/riscv/lib/fdt_fixup.c b/arch/riscv/lib/fdt_fixup.c
index 1fce414909..af12e484db 100644
--- a/arch/riscv/lib/fdt_fixup.c
+++ b/arch/riscv/lib/fdt_fixup.c
@@ -100,3 +100,18 @@ int riscv_board_reserved_mem_fixup(void *fdt)
return 0;
}
+
+#ifdef CONFIG_OF_BOARD_FIXUP
+int board_fix_fdt(void *fdt)
+{
+ int err;
+
+ err = riscv_board_reserved_mem_fixup(fdt);
+ if (err < 0) {
+ printf("failed to fixup DT for reserved memory: %d\n", err);
+ return err;
+ }
+
+ return 0;
+}
+#endif