diff options
author | Tom Rini <trini@konsulko.com> | 2022-05-11 13:27:44 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-05-11 13:27:44 -0400 |
commit | c387e62614713d0cc9e3ed022b86c9f320b02853 (patch) | |
tree | b4a66ef7e1e2c15ee7ae8d3576225eed29880b93 /common/board_r.c | |
parent | 21e25992c86306b41caafcf85efc47d66f5efa6e (diff) | |
parent | db26c507c925f8ae0ebad9e22b67b2df8ae2184b (diff) |
Merge branch '2022-05-11-Kconfig-cleanups-etc'
- Migrate CONFIG_MTD_CONCAT to Kconfig, use CONFIG_VAL/IS_ENABLED in
more places, rename SPL_LEGACY_IMAGE_SUPPORT to
SPL_LEGACY_IMAGE_FORMAT and update some related dependencies for TI
platforms.
Diffstat (limited to 'common/board_r.c')
-rw-r--r-- | common/board_r.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/common/board_r.c b/common/board_r.c index 93c9c2e50da..6f4aca2077d 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -61,6 +61,7 @@ #include <wdt.h> #include <asm-generic/gpio.h> #include <efi_loader.h> +#include <relocate.h> DECLARE_GLOBAL_DATA_PTR; @@ -810,19 +811,15 @@ void board_init_r(gd_t *new_gd, ulong dest_addr) if (CONFIG_IS_ENABLED(X86_64) && !IS_ENABLED(CONFIG_EFI_APP)) arch_setup_gd(new_gd); -#ifdef CONFIG_NEEDS_MANUAL_RELOC - int i; -#endif - #if !defined(CONFIG_X86) && !defined(CONFIG_ARM) && !defined(CONFIG_ARM64) gd = new_gd; #endif gd->flags &= ~GD_FLG_LOG_READY; -#ifdef CONFIG_NEEDS_MANUAL_RELOC - for (i = 0; i < ARRAY_SIZE(init_sequence_r); i++) - init_sequence_r[i] += gd->reloc_off; -#endif + if (IS_ENABLED(CONFIG_NEEDS_MANUAL_RELOC)) { + for (int i = 0; i < ARRAY_SIZE(init_sequence_r); i++) + MANUAL_RELOC(init_sequence_r[i]); + } if (initcall_run_list(init_sequence_r)) hang(); |