Print image address the bootm command assumed when it complains about wrong image format.
PATCH 1/1 Print image address the bootm command assumed when it complains about wrong image format.
An embedded and charset-unspecified text was scrubbed...
Name: make-bootm-command-print-image-address-on-error.patch
Url: http://lists.denx.de/pipermail/u-boot/attachments/20081204/c7baf47a/attachment.txt
PATCH 1/1 Print image address the bootm command assumed when it complains about wrong image format.
Dear Remy Bohmer,
Quoted 13 lines · In message <[email protected]> you wrote:
If the error "Wrong Image Format for bootm command" is displayed, it helps debugging if the address is printed where it assumed the image to be.
Signed-off-by Remy Bohmer <[email protected]>--- common/cmd_bootm.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)Index:
u-boot-usb.new/common/cmd_bootm.c
===================================================================
common/cmd_bootm.c static int bootm_load_os(image_info_t os · line 350
Quoted 5 lines
common/cmd_bootm.c +1
-1@@ -347,7 +347,8 @@ static int bootm_load_os(image_info_t osputs ("OK\n" );break ;case IH_COMP_GZIP : -printf (" Uncompressing %s ... " , type_name); + printf(" Uncompressing %s ... from:0x%x(0x%x) to 0x%lx",
Please do not change coding style within a file. All the rest of this file uses a space between the function name and the (, so please keep that.
Also, the "..." are intended to mean "this is running now, please wait", and thus should be at the end of the line.
common/cmd_bootm.c static int bootm_load_os(image_info_t os · line 351
Quoted 1 line
common/cmd_bootm.c +1
-0+ type_name, (unsigned int)image_start, unc_len, load);
You mention that this is a debug help, so you probably want to make it depend of DEBUG ?
common/cmd_bootm.c static int bootm_load_os(image_info_t os · line 354
Quoted 4 lines
common/cmd_bootm.c +2
-1default : -printf ("Wrong Image Format for %s command\n" , cmdtp->name); +printf ("Wrong Image Format at addr:0x%08lx for %s command\n" , + img_addr, cmdtp->name);
See above about coding style.
I don't really understand why this is needed. You know where your images are, don't you?
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de "If people are good only because they fear punishment, and hope for reward, then we are a sorry lot indeed." - Albert Einstein