[PATCH] scripts: imx: fix header entry offset

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


Header entry is at a fixed offset and doesn't rely on header lenght.
Use header lenght create a bug when adding a signed firmware like
the HDMI firmware for IMX8MQ.

Fixes: 1c18863354dc ("scripts: imx-image: header_v2: add header_len parameter")
Signed-off-by: Benjamin Gaignard <benjamin.gaignard@xxxxxxxxxxxxx>
 scripts/imx/imx-image.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/imx/imx-image.c b/scripts/imx/imx-image.c
index bc2e7af5d6..4f4d5526ed 100644
--- a/scripts/imx/imx-image.c
+++ b/scripts/imx/imx-image.c
@@ -322,7 +322,7 @@ add_header_v2(const struct config_data *data, void *buf, uint32_t offset,
 	hdr->header.length	= htobe16(32);
 	hdr->header.version	= IVT_VERSION;
-	hdr->entry		= loadaddr + header_len;
+	hdr->entry		= loadaddr + HEADER_LEN;
 	if (dcdsize)
 		hdr->dcd_ptr = loadaddr + offset + offsetof(struct imx_flash_header_v2, dcd_header);
 	if (create_usb_image) {

[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux