[PATCH v2025.09.y 02/58] scripts: imx: fix string in further auth block

Ahmad Fatoum a.fatoum at pengutronix.de
Fri Mar 13 06:24:46 PDT 2026


From: Matthias Zoechmann <matthias.zoechmann at ife-doors.com>

If an additional block to be authenticated is added via
'hab_do_block off+size at addr' the CST tool will fail.
It seems that an own line is expected for each authentication
block. Add a '\' and linefeed after the comma to avoid a fail of CST.

(cherry picked from commit 8a8dffde3e6f7c6fd2ba19ac8444304be67e1e3a)

Signed-off-by: Matthias Zoechmann <matthias.zoechmann at ife-doors.com>
Link: https://lore.barebox.org/20250901-imx6-usb-uuu-v1-1-1194bb6135ae@pengutronix.de
Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
 scripts/imx/imx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/imx/imx.c b/scripts/imx/imx.c
index 26027f0f3548..6dabaf59c159 100644
--- a/scripts/imx/imx.c
+++ b/scripts/imx/imx.c
@@ -488,7 +488,7 @@ static int do_hab_blocks(struct config_data *data, int argc, char *argv[])
 			return -EINVAL;
 		}
 
-		ret = asprintf(&str, ", 0x%08x 0x%08x 0x%08x \"%s\"", addr, off, size, data->outfile);
+		ret = asprintf(&str, ", \\\n 0x%08x 0x%08x 0x%08x \"%s\"", addr, off, size, data->outfile);
 		if (ret < 0)
 			return -ENOMEM;
 
-- 
2.47.3




More information about the barebox mailing list