* [U-Boot] [PATCH] common/cmd_fdt.c: fix wrong data displayed in fdt print [not found] <2011052301> @ 2011-05-23 7:53 ` Haojian Zhuang 2011-06-01 20:45 ` Wolfgang Denk 0 siblings, 1 reply; 3+ messages in thread From: Haojian Zhuang @ 2011-05-23 7:53 UTC (permalink / raw) To: u-boot From: Haojian Zhuang <haojian.zhuang@gmail.com> All data in dtb is big endian. Some ARM devices are little-endian. In print_data(), it displays data with big-endian format. For ARM device, data should be converted to little-endian first. Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Cc: Gerald Van Baren <vanbaren@cideas.com> --- common/cmd_fdt.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/common/cmd_fdt.c b/common/cmd_fdt.c index 3d0c2b7..9bdecca 100644 --- a/common/cmd_fdt.c +++ b/common/cmd_fdt.c @@ -665,7 +665,7 @@ static void print_data(const void *data, int len) printf("<"); for (j = 0, p = data; j < len/4; j ++) - printf("0x%x%s", p[j], j < (len/4 - 1) ? " " : ""); + printf("0x%x%s", fdt32_to_cpu(p[j]), j < (len/4 - 1) ? " " : ""); printf(">"); } else { /* anything else... hexdump */ const u8 *s; -- 1.7.4.1 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* [U-Boot] [PATCH] common/cmd_fdt.c: fix wrong data displayed in fdt print 2011-05-23 7:53 ` [U-Boot] [PATCH] common/cmd_fdt.c: fix wrong data displayed in fdt print Haojian Zhuang @ 2011-06-01 20:45 ` Wolfgang Denk 2011-06-01 21:02 ` Jerry Van Baren 0 siblings, 1 reply; 3+ messages in thread From: Wolfgang Denk @ 2011-06-01 20:45 UTC (permalink / raw) To: u-boot Dear Haojian Zhuang, In message <1306137210-31942-1-git-send-email-haojian.zhuang@marvell.com> you wrote: > From: Haojian Zhuang <haojian.zhuang@gmail.com> > > All data in dtb is big endian. Some ARM devices are little-endian. > In print_data(), it displays data with big-endian format. For ARM device, > data should be converted to little-endian first. > > Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> > Cc: Gerald Van Baren <vanbaren@cideas.com> > --- > common/cmd_fdt.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) Applied, thanks. Gerald, I hope this is OK with you? Best regards, Wolfgang Denk -- 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 The software required `Windows 95 or better', so I installed Linux. ^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot] [PATCH] common/cmd_fdt.c: fix wrong data displayed in fdt print 2011-06-01 20:45 ` Wolfgang Denk @ 2011-06-01 21:02 ` Jerry Van Baren 0 siblings, 0 replies; 3+ messages in thread From: Jerry Van Baren @ 2011-06-01 21:02 UTC (permalink / raw) To: u-boot On 06/01/2011 04:45 PM, Wolfgang Denk wrote: > Dear Haojian Zhuang, > > In message<1306137210-31942-1-git-send-email-haojian.zhuang@marvell.com> you wrote: [snip] > Applied, thanks. > > Gerald, I hope this is OK with you? Yes. > Best regards, > Wolfgang Denk Thanks, gvb ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-06-01 21:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <2011052301>
2011-05-23 7:53 ` [U-Boot] [PATCH] common/cmd_fdt.c: fix wrong data displayed in fdt print Haojian Zhuang
2011-06-01 20:45 ` Wolfgang Denk
2011-06-01 21:02 ` Jerry Van Baren
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox