[U-Boot-Users] [new uImage] Code available on new-image branch of u-boot-testing repo
Kumar Gala
galak at kernel.crashing.org
Tue Feb 12 18:17:23 CET 2008
On Feb 7, 2008, at 10:29 AM, Kumar Gala wrote:
>
> On Feb 7, 2008, at 10:15 AM, Bartlomiej Sieka wrote:
>
>> Kumar Gala wrote:
>>> Here is a rough patch to common/cmd_bootm.c that passed load_end
>>> down to
>>> the do_bootm_* commands. I haven't updated the lib_*/bootm.c at
>>> this
>>> point.
>>> I think this is useful to help the bootm commands know exactly what
>>> memory
>>> is used and what is freed. There are situations that I'd like to
>>> get
>>> working with the new code like being able to boot a kernel at 256M
>>> and
>>> have the ramdisk and device tree exist about this 256M base.
>>> - k
>>> diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
>>> index 2ddb191..b36d09e 100644
>>> --- a/common/cmd_bootm.c
>>> +++ b/common/cmd_bootm.c
>>> @@ -90,7 +90,7 @@ extern int do_reset (cmd_tbl_t *cmdtp, int flag,
>>> int argc, char *argv[]);
>>> typedef void boot_os_fn (cmd_tbl_t *cmdtp, int flag,
>>> int argc, char *argv[],
>>> image_header_t *hdr, /* of image to boot */
>>> - int verify); /* getenv("verify")[0] != 'n' */
>>> + int verify, ulong load_end); /* getenv("verify")[0] != 'n' */
>>> extern boot_os_fn do_bootm_linux;
>>> static boot_os_fn do_bootm_netbsd;
>>> @@ -234,36 +234,36 @@ int do_bootm (cmd_tbl_t *cmdtp, int flag, int
>>> argc, char *argv[])
>>> #ifdef CONFIG_SILENT_CONSOLE
>>> fixup_silent_linux();
>>> #endif
>>> - do_bootm_linux (cmdtp, flag, argc, argv, hdr, verify);
>>> + do_bootm_linux (cmdtp, flag, argc, argv, hdr, verify,
>>> load_end);
>>> break;
>>
>> Hi Kumar,
>>
>> In our development code for the new format we need even more data to
>> be
>> passed down to do_bootm_* flavors. We are doing this by passing a
>> pointer to a structure:
>>
>> - do_bootm_linux (cmdtp, flag, argc, argv, hdr, verify);
>> + do_bootm_linux (cmdtp, flag, argc, argv, &images,
>> verify);
>>
>>
>> Where images is of type bootm_headers_t, defined like this:
>>
>> /*
>> * Legacy and FIT format headers used by do_bootm() and
>> do_bootm_<os>()
>> * routines.
>> */
>> typedef struct bootm_headers {
>> /*
>> * Legacy os image header, if it is a multi component image
>> * then get_ramdisk() and get_fdt() will attempt to get
>> * data from second and third component accordingly.
>> */
>> image_header_t *legacy_hdr_os;
>> ulong legacy_hdr_valid;
>>
>> #if defined(CONFIG_FIT)
>> void *fit_hdr_os; /* os FIT image header */
>> char *fit_uname_os; /* os subimage node unit name */
>>
>> void *fit_hdr_rd; /* init ramdisk FIT img header
>> */
>> char *fit_uname_rd; /* init ramdisk node unit name
>> */
>>
>> #if defined(CONFIG_PPC)
>> void *fit_hdr_fdt; /* FDT blob FIT image header */
>> char *fit_uname_fdt; /* FDT blob node unit name */
>> #endif
>> #endif
>> } bootm_headers_t;
>>
>>
>> Perhaps it would be a good idea to add your load_end to
>> bootm_headers?
>> In any case, let's get back to this once the above mentioned code is
>> posted to the ML.
>
> sounds good, any eta on when this patch will show up?
Any update on the patch?
One of the ideas I have is I'd like to see if we can make it possible
to do the equiv of bootm via a series of commands from the u-boot
command line.
For example, I don't believe we have a way today to just decompress a
uImage file.
- k
More information about the U-Boot
mailing list