diff options
author | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2021-10-12 00:00:13 +0300 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-10-18 20:19:50 +0300 |
commit | 2e8d2f88439d7437f04a6af1d206270f9a2240d3 (patch) | |
tree | 696b2966fe4df48f0f2a0fcdc76713f4f17644ec /board/AndesTech | |
parent | d990f7d75d3dcf45a9220abc900495f00792f414 (diff) | |
download | u-boot-2e8d2f88439d7437f04a6af1d206270f9a2240d3.tar.xz |
riscv: Remove OF_PRIOR_STAGE from RISC-V boards
At some point back in 2018 prior_stage_fdt_address and OF_PRIOR_STAGE got
introduced, in order to support a DTB handed over by an earlier stage boo
loader. However we have another option in the Kconfig (OF_BOARD) which has
identical semantics.
On RISC-V some of the boards pick up the DTB from a1 and copy it in their
private gd_t. Apart from that they copy it to prior_stage_fdt_address, if
the Kconfig option is selected, which is unnecessary.
So let's switch the config option for those boards to OF_BOARD and define
the required board_fdt_blob_setup() for them.
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
Diffstat (limited to 'board/AndesTech')
-rw-r--r-- | board/AndesTech/ax25-ae350/ax25-ae350.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/board/AndesTech/ax25-ae350/ax25-ae350.c b/board/AndesTech/ax25-ae350/ax25-ae350.c index 15da58a314..b28894ed46 100644 --- a/board/AndesTech/ax25-ae350/ax25-ae350.c +++ b/board/AndesTech/ax25-ae350/ax25-ae350.c @@ -21,7 +21,6 @@ DECLARE_GLOBAL_DATA_PTR; -extern phys_addr_t prior_stage_fdt_address; /* * Miscellaneous platform dependent initializations */ @@ -57,7 +56,13 @@ ulong board_flash_get_legacy(ulong base, int banknum, flash_info_t *info) void *board_fdt_blob_setup(void) { +#if CONFIG_IS_ENABLED(OF_BOARD) + return (void *)(ulong)gd->arch.firmware_fdt_addr; +#elif CONFIG_IS_ENABLED(OF_SEPARATE) return (void *)CONFIG_SYS_FDT_BASE; +#else + return NULL; +#endif } int smc_init(void) |