The bootdata.size should contain the IVT offset part, but the calculation
in imximage tool does not have. This will cause some data at
the end of image not be loaded into memory.

Signed-off-by: Ye.Li <b37...@freescale.com>
---
 tools/imximage.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/imximage.c b/tools/imximage.c
index faba238..526b7d4 100644
--- a/tools/imximage.c
+++ b/tools/imximage.c
@@ -587,7 +587,7 @@ static void imximage_set_header(void *ptr, struct stat 
*sbuf, int ifd,
         *
         * The remaining fraction of a block bytes would not be loaded!
         */
-       *header_size_ptr = ROUND(sbuf->st_size, 4096);
+       *header_size_ptr = ROUND((sbuf->st_size + imximage_ivt_offset), 4096);
 
        if (csf_ptr && imximage_csf_size) {
                *csf_ptr = params->ep - imximage_init_loadsize +
-- 
1.7.4.1

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to