From: David Woodhouse <dwmw@xxxxxxxxxxxx> Signed-off-by: David Woodhouse <dwmw at amazon.co.uk> --- kexec/kexec-uImage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kexec/kexec-uImage.c b/kexec/kexec-uImage.c index 667cd93..49f266a 100644 --- a/kexec/kexec-uImage.c +++ b/kexec/kexec-uImage.c @@ -236,7 +236,7 @@ int uImage_load(const unsigned char *buf, off_t len, struct Image_info *image) { const struct image_header *header = (const struct image_header *)buf; const unsigned char *img_buf = buf + sizeof(struct image_header); - off_t img_len = header->ih_size; + off_t img_len = be32_to_cpu(header->ih_size); /* * Prevent loading a modified image. -- 2.9.3