diff options
author | Rob Herring <rob.herring@calxeda.com> | 2012-03-26 13:16:59 -0500 |
---|---|---|
committer | John Rigby <john.rigby@linaro.org> | 2012-12-06 13:51:48 -0700 |
commit | 5af2769faee0452d6ee2f111511fe3ac3fb713b2 (patch) | |
tree | c572c8266ae21a1e6ce39994414a28675593d21b | |
parent | 021961e79c8006fd5528fc9f901f0f7d258c1ad4 (diff) |
pxe: use bootz instead of bootm
Signed-off-by: Rob Herring <rob.herring@calxeda.com>
-rw-r--r-- | common/cmd_pxe.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/common/cmd_pxe.c b/common/cmd_pxe.c index ed09d2193..0d0efa441 100644 --- a/common/cmd_pxe.c +++ b/common/cmd_pxe.c @@ -597,6 +597,7 @@ static int label_localboot(struct pxe_label *label) static void label_boot(struct pxe_label *label) { char *bootm_argv[] = { "bootm", NULL, NULL, NULL, NULL }; + char initrd_str[22]; int bootm_argc = 3; label_print(label); @@ -621,7 +622,10 @@ static void label_boot(struct pxe_label *label) return; } - bootm_argv[2] = getenv("ramdisk_addr_r"); + bootm_argv[2] = initrd_str; + strcpy(bootm_argv[2], getenv("ramdisk_addr_r")); + strcat(bootm_argv[2], ":"); + strcat(bootm_argv[2], getenv("filesize")); } else { bootm_argv[2] = "-"; } @@ -665,7 +669,11 @@ static void label_boot(struct pxe_label *label) if (bootm_argv[3]) bootm_argc = 4; +#ifdef CONFIG_CMD_BOOTZ + do_bootz(NULL, 0, bootm_argc, bootm_argv); +#else do_bootm(NULL, 0, bootm_argc, bootm_argv); +#endif } /* |