summaryrefslogtreecommitdiff
path: root/lib_sparc
diff options
context:
space:
mode:
authorKumar Gala <galak@kernel.crashing.org>2008-08-15 08:24:36 -0500
committerWolfgang Denk <wd@denx.de>2008-08-26 23:31:33 +0200
commitc160a9544743e80e8889edb2275538e7764ce334 (patch)
tree484a54af158348313ed5f3b4890a6bbb56e7e468 /lib_sparc
parent20220d22b9f41446288588cd2e457e0077a18bed (diff)
downloadu-boot-imx-c160a9544743e80e8889edb2275538e7764ce334.zip
u-boot-imx-c160a9544743e80e8889edb2275538e7764ce334.tar.gz
u-boot-imx-c160a9544743e80e8889edb2275538e7764ce334.tar.bz2
bootm: refactor entry point code
Move entry point code out of each arch and into common code. Keep the entry point in the bootm_headers_t images struct. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'lib_sparc')
-rw-r--r--lib_sparc/bootm.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/lib_sparc/bootm.c b/lib_sparc/bootm.c
index b1a3d98..ac15396 100644
--- a/lib_sparc/bootm.c
+++ b/lib_sparc/bootm.c
@@ -87,7 +87,7 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
bootm_headers_t * images)
{
char *bootargs;
- ulong ep, load;
+ ulong load;
ulong initrd_start, initrd_end;
ulong rd_data_start, rd_data_end, rd_len;
unsigned int data, len, checksum;
@@ -97,17 +97,9 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
int ret;
if (images->legacy_hdr_valid) {
- ep = image_get_ep(images->legacy_hdr_os);
load = image_get_load(images->legacy_hdr_os);
#if defined(CONFIG_FIT)
} else if (images->fit_uname_os) {
- int ret = fit_image_get_entry(images->fit_hdr_os,
- images->fit_noffset_os, &ep);
- if (ret) {
- puts("Can't get entry point property!\n");
- goto error;
- }
-
ret = fit_image_get_load(images->fit_hdr_os,
images->fit_noffset_os, &load);
if (ret) {
@@ -124,7 +116,7 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[],
linux_hdr = (void *)load;
/* */
- kernel = (void (*)(struct linux_romvec *, void *))ep;
+ kernel = (void (*)(struct linux_romvec *, void *))images->ep;
/* check for a SPARC kernel */
if ((linux_hdr->hdr[0] != 'H') ||