summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2013-11-10 10:26:59 -0700
committerSimon Glass <sjg@chromium.org>2014-01-08 17:24:38 -0700
commit808434cdbd70b6633c99fe2974af7d25316cc593 (patch)
treee867522a0f02358fedd4afc11b49852a5f830d42 /common
parent6ebcab8de7c38ca0b2cc5215c5b3e7ccf5f9d0d7 (diff)
downloadu-boot-imx-808434cdbd70b6633c99fe2974af7d25316cc593.zip
u-boot-imx-808434cdbd70b6633c99fe2974af7d25316cc593.tar.gz
u-boot-imx-808434cdbd70b6633c99fe2974af7d25316cc593.tar.bz2
sandbox: Allow return from board_init_f()
The execution flow becomes easier if we can return from board_init_f() as ARM does. We can control things from start.c instead of having to call back into that file from other places. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common')
-rw-r--r--common/board_f.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/common/board_f.c b/common/board_f.c
index fcfd713..6f77e1d 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -772,7 +772,7 @@ static int setup_reloc(void)
}
/* ARM calls relocate_code from its crt0.S */
-#if !defined(CONFIG_ARM)
+#if !defined(CONFIG_ARM) && !defined(CONFIG_SANDBOX)
static int jump_to_copy(void)
{
@@ -792,8 +792,6 @@ static int jump_to_copy(void)
* (CPU cache)
*/
board_init_f_r_trampoline(gd->start_addr_sp);
-#elif defined(CONFIG_SANDBOX)
- board_init_r(gd->new_gd, 0);
#else
relocate_code(gd->start_addr_sp, gd->new_gd, gd->relocaddr);
#endif
@@ -995,7 +993,7 @@ static init_fnc_t init_sequence_f[] = {
INIT_FUNC_WATCHDOG_RESET
reloc_fdt,
setup_reloc,
-#ifndef CONFIG_ARM
+#if !defined(CONFIG_ARM) && !defined(CONFIG_SANDBOX)
jump_to_copy,
#endif
NULL,
@@ -1015,7 +1013,7 @@ void board_init_f(ulong boot_flags)
if (initcall_run_list(init_sequence_f))
hang();
-#ifndef CONFIG_ARM
+#if !defined(CONFIG_ARM) && !defined(CONFIG_SANDBOX)
/* NOTREACHED - jump_to_copy() does not return */
hang();
#endif