From 3c10dc95bdd0706ff85ffdc25ecd6381c3d51e4c Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 6 Dec 2019 21:41:34 -0700 Subject: 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 Reviewed-by: Bin Meng --- common/board_r.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'common/board_r.c') 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 #endif +#include #include #include #include @@ -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, -- cgit