summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorWolfgang Denk <wd@pollux.denx.de>2006-10-11 23:54:37 +0200
committerWolfgang Denk <wd@pollux.denx.de>2006-10-11 23:54:37 +0200
commit7e2a24dca9a3213f0b4941562e4387e20bec3e2d (patch)
treed04e0a5852637f365621cea6691c78d3d5e55d3d /common
parentfb883a521e04437acfe989de3e152b2e4866856b (diff)
parent7376eb87aaa601f728f9b8e5e9cd2711a67f529e (diff)
downloadu-boot-imx-7e2a24dca9a3213f0b4941562e4387e20bec3e2d.zip
u-boot-imx-7e2a24dca9a3213f0b4941562e4387e20bec3e2d.tar.gz
u-boot-imx-7e2a24dca9a3213f0b4941562e4387e20bec3e2d.tar.bz2
Merge with http://opensource.freescale.com/pub/scm/u-boot-85xx.git#for_wd
Diffstat (limited to 'common')
-rw-r--r--common/cmd_bootm.c13
-rw-r--r--common/ft_build.c12
2 files changed, 13 insertions, 12 deletions
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index bc84ae3..d913f5c 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -510,7 +510,7 @@ fixup_silent_linux ()
#endif /* CONFIG_SILENT_CONSOLE */
#ifdef CONFIG_PPC
-static void
+static void __attribute__((noinline))
do_bootm_linux (cmd_tbl_t *cmdtp, int flag,
int argc, char *argv[],
ulong addr,
@@ -625,7 +625,7 @@ do_bootm_linux (cmd_tbl_t *cmdtp, int flag,
/* Look for a '-' which indicates to ignore the ramdisk argument */
if (argc >= 3 && strcmp(argv[2], "-") == 0) {
debug ("Skipping initrd\n");
- data = 0;
+ len = data = 0;
}
else
#endif
@@ -900,8 +900,6 @@ do_bootm_linux (cmd_tbl_t *cmdtp, int flag,
(*kernel) (kbd, initrd_start, initrd_end, cmd_start, cmd_end);
#else
- ft_setup(of_flat_tree, kbd, initrd_start, initrd_end);
- /* ft_dump_blob(of_flat_tree); */
#if defined(CFG_INIT_RAM_LOCK) && !defined(CONFIG_E500)
unlock_ram_in_cache();
@@ -917,9 +915,12 @@ do_bootm_linux (cmd_tbl_t *cmdtp, int flag,
if (getenv("disable_of") != NULL)
(*kernel) ((bd_t *)of_flat_tree, initrd_start, initrd_end,
cmd_start, cmd_end);
- else
+ else {
+ ft_setup(of_flat_tree, kbd, initrd_start, initrd_end);
+ /* ft_dump_blob(of_flat_tree); */
(*kernel) ((bd_t *)of_flat_tree, (ulong)kernel, 0, 0, 0);
-
+ }
+
#endif
}
#endif /* CONFIG_PPC */
diff --git a/common/ft_build.c b/common/ft_build.c
index f76c582..980e40f 100644
--- a/common/ft_build.c
+++ b/common/ft_build.c
@@ -87,9 +87,9 @@ static int lookup_string(struct ft_cxt *cxt, const char *name)
p = cxt->p;
while (p < cxt->p_end) {
- if (strcmp(p, name) == 0)
+ if (strcmp((char *)p, name) == 0)
return p - cxt->p;
- p += strlen(p) + 1;
+ p += strlen((char *)p) + 1;
}
return -1;
@@ -103,7 +103,7 @@ void ft_prop(struct ft_cxt *cxt, const char *name, const void *data, int sz)
if (off == -1) {
memcpy(cxt->p_end, name, strlen(name) + 1);
off = cxt->p_end - cxt->p;
- cxt->p_end += strlen(name) + 2;
+ cxt->p_end += strlen(name) + 1;
}
/* now put offset from beginning of *STRUCTURE* */
@@ -143,9 +143,9 @@ void ft_init_cxt(struct ft_cxt *cxt, void *blob)
cxt->p_rsvmap += SIZE_OF_RSVMAP_ENTRY;
}
- cxt->p_start = (char*)bph + bph->off_dt_struct;
- cxt->p_end = (char *)bph + bph->totalsize;
- cxt->p = (char *)bph + bph->off_dt_strings;
+ cxt->p_start = (u8 *)bph + bph->off_dt_struct;
+ cxt->p_end = (u8 *)bph + bph->totalsize;
+ cxt->p = (u8 *)bph + bph->off_dt_strings;
}
/* add a reserver physical area to the rsvmap */