diff options
author | Simon Glass <sjg@chromium.org> | 2019-12-06 21:41:34 -0700 |
---|---|---|
committer | Bin Meng <bmeng.cn@gmail.com> | 2019-12-15 08:48:33 +0800 |
commit | 3c10dc95bdd0706ff85ffdc25ecd6381c3d51e4c (patch) | |
tree | fe9a2f30a15fdf3fc36fb7c7194a568b981e4024 /common/board_r.c | |
parent | 553cb06887825314e74a9bdac337467c77d1db88 (diff) |
binman: Add a library to access binman entries
SPL and TPL can access information about binman entries using link-time
symbols but this is not available in U-Boot proper. Of course it could be
made available, but the intention is to just read the device tree.
Add support for this, so that U-Boot can locate entries.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'common/board_r.c')
-rw-r--r-- | common/board_r.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/common/board_r.c b/common/board_r.c index 5464172259..9902c51c5e 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -18,6 +18,7 @@ #if defined(CONFIG_CMD_BEDBUG) #include <bedbug/type.h> #endif +#include <binman.h> #include <command.h> #include <console.h> #include <dm.h> @@ -347,6 +348,14 @@ static int initr_manual_reloc_cmdtable(void) } #endif +static int initr_binman(void) +{ + if (!CONFIG_IS_ENABLED(BINMAN_FDT)) + return 0; + + return binman_init(); +} + #if defined(CONFIG_MTD_NOR_FLASH) static int initr_flash(void) { @@ -697,6 +706,7 @@ static init_fnc_t init_sequence_r[] = { #ifdef CONFIG_EFI_LOADER efi_memory_init, #endif + initr_binman, stdio_init_tables, initr_serial, initr_announce, |