* [U-Boot] [PATCH] bugfix: image header pointer change.
@ 2010-11-26 23:59 Baidu Boy
2010-11-27 0:47 ` Mike Frysinger
0 siblings, 1 reply; 6+ messages in thread
From: Baidu Boy @ 2010-11-26 23:59 UTC (permalink / raw)
To: u-boot
images.legacy_hdr_os should point to the new copied structure,
not the original structure which may be over written.
Signed-off-by: Baidu Boy <liucai.lfn@gmail.com>
---
common/cmd_bootm.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 1a024f1..9ad5b19 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -896,10 +896,9 @@ static void *boot_get_kernel (cmd_tbl_t *cmdtp,
int flag, int argc, char * const
memmove (&images->legacy_hdr_os_copy, hdr, sizeof(image_header_t));
/* save pointer to image header */
- images->legacy_hdr_os = hdr;
-
+ images->legacy_hdr_os = &images->legacy_hdr_os_copy;
images->legacy_hdr_valid = 1;
- show_boot_progress (6);
+ show_boot_progress (6);
break;
#if defined(CONFIG_FIT)
case IMAGE_FORMAT_FIT:
--
1.7.3.1.msysgit.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] bugfix: image header pointer change.
2010-11-26 23:59 [U-Boot] [PATCH] bugfix: image header pointer change Baidu Boy
@ 2010-11-27 0:47 ` Mike Frysinger
2010-11-27 1:08 ` Baidu Boy
0 siblings, 1 reply; 6+ messages in thread
From: Mike Frysinger @ 2010-11-27 0:47 UTC (permalink / raw)
To: u-boot
On Friday, November 26, 2010 18:59:42 Baidu Boy wrote:
> - show_boot_progress (6);
> + show_boot_progress (6);
this doesnt seem to actually be changing anything. you should avoid unrelated
syntax changes with functional changes.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20101126/64a2c460/attachment.pgp
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] bugfix: image header pointer change.
2010-11-27 0:47 ` Mike Frysinger
@ 2010-11-27 1:08 ` Baidu Boy
2010-11-27 2:33 ` Mike Frysinger
0 siblings, 1 reply; 6+ messages in thread
From: Baidu Boy @ 2010-11-27 1:08 UTC (permalink / raw)
To: u-boot
Hi,Mike:
the purpose of below code is to copy the image header to the static
variable images.legacy_hdr_os_copy, and then the images.legacy_hdr_os
points to the
image header in the static variable images.
------
memmove (&images->legacy_hdr_os_copy, hdr, sizeof(image_header_t));
/* save pointer to image header */
images->legacy_hdr_os = hdr;
------
but the original code still lets the mages->legacy_hdr_os to point to
the header of uImage which may be overwritten in the decompress
progress.
That is not what we want.
Thanks
2010/11/27 Mike Frysinger <vapier@gentoo.org>:
> On Friday, November 26, 2010 18:59:42 Baidu Boy wrote:
>> - ? ? ? ? ? ? show_boot_progress (6);
>> + ? ? ? ? ? ? show_boot_progress (6);
>
> this doesnt seem to actually be changing anything. ?you should avoid unrelated
> syntax changes with functional changes.
> -mike
>
--
------
Best Regards
Leo Liu
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] bugfix: image header pointer change.
2010-11-27 1:08 ` Baidu Boy
@ 2010-11-27 2:33 ` Mike Frysinger
2010-11-27 3:03 ` Baidu Boy
0 siblings, 1 reply; 6+ messages in thread
From: Mike Frysinger @ 2010-11-27 2:33 UTC (permalink / raw)
To: u-boot
On Friday, November 26, 2010 20:08:07 Baidu Boy wrote:
> Hi,Mike:
please do not top post
> the purpose of below code is to copy the image header to the static
please read the exact text i quoted
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20101126/411d7edb/attachment.pgp
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] bugfix: image header pointer change.
2010-11-27 2:33 ` Mike Frysinger
@ 2010-11-27 3:03 ` Baidu Boy
2010-11-27 3:39 ` Mike Frysinger
0 siblings, 1 reply; 6+ messages in thread
From: Baidu Boy @ 2010-11-27 3:03 UTC (permalink / raw)
To: u-boot
I get your point. So I need to re-send a patch?
2010/11/27 Mike Frysinger <vapier@gentoo.org>:
> On Friday, November 26, 2010 20:08:07 Baidu Boy wrote:
>> Hi,Mike:
>
> please do not top post
>
>> the purpose of below code is to copy the image header to the static
>
> please read the exact text i quoted
> -mike
>
--
------
Best Regards
Leo Liu
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] bugfix: image header pointer change.
2010-11-27 3:03 ` Baidu Boy
@ 2010-11-27 3:39 ` Mike Frysinger
0 siblings, 0 replies; 6+ messages in thread
From: Mike Frysinger @ 2010-11-27 3:39 UTC (permalink / raw)
To: u-boot
On Friday, November 26, 2010 22:03:26 Baidu Boy wrote:
> I get your point. So I need to re-send a patch?
again, please stop top posting. it'd probably be good to send a new patch
that didnt touch the boot progress line.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20101126/34d5f2f2/attachment.pgp
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2010-11-27 3:39 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-26 23:59 [U-Boot] [PATCH] bugfix: image header pointer change Baidu Boy
2010-11-27 0:47 ` Mike Frysinger
2010-11-27 1:08 ` Baidu Boy
2010-11-27 2:33 ` Mike Frysinger
2010-11-27 3:03 ` Baidu Boy
2010-11-27 3:39 ` Mike Frysinger
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.