summaryrefslogtreecommitdiff
path: root/lib_i386
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2008-04-13 19:42:19 -0400
committerWolfgang Denk <wd@denx.de>2008-04-18 00:31:41 -0700
commita49864593e083a5d0779fb9ca98e5a0f2053183d (patch)
treecf69cd393e711b73115c743103ad88c9aba944cd /lib_i386
parent017e9b7925f74878d0e9475388cca9bda5ef9482 (diff)
downloadu-boot-imx-a49864593e083a5d0779fb9ca98e5a0f2053183d.zip
u-boot-imx-a49864593e083a5d0779fb9ca98e5a0f2053183d.tar.gz
u-boot-imx-a49864593e083a5d0779fb9ca98e5a0f2053183d.tar.bz2
allow ports to override go behavior
Split the arch-specific logic out of the common go code and into a dedicated weak function called do_go_exec() that lives in cpu directories. This will need review from i386/nios people to make sure I didn't break them.
Diffstat (limited to 'lib_i386')
-rw-r--r--lib_i386/board.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib_i386/board.c b/lib_i386/board.c
index 47fbab4..22191e6 100644
--- a/lib_i386/board.c
+++ b/lib_i386/board.c
@@ -421,3 +421,11 @@ void hang (void)
puts ("### ERROR ### Please RESET the board ###\n");
for (;;);
}
+
+unsigned long do_go_exec (ulong (*entry)(int, char *[]), int argc, char *argv[])
+{
+ /*
+ * Nios function pointers are address >> 1
+ */
+ return (entry >> 1) (argc, argv);
+}