aboutsummaryrefslogtreecommitdiffstats
path: root/lib_blackfin
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2008-10-11 21:44:00 -0400
committerMike Frysinger <vapier@gentoo.org>2009-01-28 13:26:15 -0500
commitb1e9435b643043dd8fbd1fcc47309c6acb7b3c8e (patch)
treeb21c55b7e58b3460c6027c04bccc2b7d6ea62443 /lib_blackfin
parentb5eba3fafcccd1979380f12a256bd0e19be3d61e (diff)
downloadu-boot-midas-b1e9435b643043dd8fbd1fcc47309c6acb7b3c8e.tar.gz
u-boot-midas-b1e9435b643043dd8fbd1fcc47309c6acb7b3c8e.tar.bz2
u-boot-midas-b1e9435b643043dd8fbd1fcc47309c6acb7b3c8e.zip
Blackfin: pass RETX to Linux
Make sure we save the value of RETX at power on and then pass it on to the kernel so that it can nicely debug a "double-fault-caused-a-reset" crash. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'lib_blackfin')
-rw-r--r--lib_blackfin/boot.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/lib_blackfin/boot.c b/lib_blackfin/boot.c
index 47e27de305..537be2bd1e 100644
--- a/lib_blackfin/boot.c
+++ b/lib_blackfin/boot.c
@@ -31,6 +31,8 @@ static char *make_command_line(void)
return dest;
}
+extern ulong bfin_poweron_retx;
+
int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images)
{
int (*appl) (char *cmdline);
@@ -49,7 +51,12 @@ int do_bootm_linux(int flag, int argc, char *argv[], bootm_headers_t *images)
cmdline = make_command_line();
icache_disable();
dcache_disable();
- (*appl) (cmdline);
+ asm __volatile__(
+ "RETX = %[retx];"
+ "CALL (%0);"
+ :
+ : "p"(appl), "q0"(cmdline), [retx] "d"(bfin_poweron_retx)
+ );
/* does not return */
return 1;