summaryrefslogtreecommitdiff
path: root/lib_m68k/bootm.c
diff options
context:
space:
mode:
authorKumar Gala <galak@kernel.crashing.org>2008-08-15 08:24:37 -0500
committerWolfgang Denk <wd@denx.de>2008-08-26 23:35:24 +0200
commitc4f9419c6b54958e0eddbcbc9e5a4a7b7ec99865 (patch)
treecdd3de7eec29a70630a6a98f1de434a4ae868cf7 /lib_m68k/bootm.c
parentc160a9544743e80e8889edb2275538e7764ce334 (diff)
downloadu-boot-imx-c4f9419c6b54958e0eddbcbc9e5a4a7b7ec99865.zip
u-boot-imx-c4f9419c6b54958e0eddbcbc9e5a4a7b7ec99865.tar.gz
u-boot-imx-c4f9419c6b54958e0eddbcbc9e5a4a7b7ec99865.tar.bz2
bootm: refactor ramdisk locating code
Move determing if we have a ramdisk and where its located into the common code. Keep track of the ramdisk start and end in the bootm_headers_t image struct. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'lib_m68k/bootm.c')
-rw-r--r--lib_m68k/bootm.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/lib_m68k/bootm.c b/lib_m68k/bootm.c
index fe658fe..241721d 100644
--- a/lib_m68k/bootm.c
+++ b/lib_m68k/bootm.c
@@ -50,7 +50,7 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag,
{
ulong sp;
- ulong rd_data_start, rd_data_end, rd_len;
+ ulong rd_len;
ulong initrd_start, initrd_end;
int ret;
@@ -95,14 +95,8 @@ void do_bootm_linux(cmd_tbl_t * cmdtp, int flag,
kernel = (void (*)(bd_t *, ulong, ulong, ulong, ulong))images->ep;
- /* find ramdisk */
- ret = boot_get_ramdisk (argc, argv, images, IH_ARCH_M68K,
- &rd_data_start, &rd_data_end);
- if (ret)
- goto error;
-
- rd_len = rd_data_end - rd_data_start;
- ret = boot_ramdisk_high (lmb, rd_data_start, rd_len,
+ rd_len = images->rd_end - images->rd_start;
+ ret = boot_ramdisk_high (lmb, images->rd_start, rd_len,
&initrd_start, &initrd_end);
if (ret)
goto error;