From 90a24cf72f8c7f511c7706e1f23de62f59fae90b Mon Sep 17 00:00:00 2001 From: Ahmad Fatoum Date: Mon, 3 Jul 2023 16:21:22 +0200 Subject: firmware: fix alignment of firmware images ASM_LGPTR is a preprocessor symbol, not a Make variable, so expanding it in the Makefile results in .p2align without an argument, which disables alignment requirement. Fix this to restore the sizeof(void *) alignment we had before. Fixes: a59e2740b4a7 ("firmware: reference pointer alignment defined in ") Reported-by: Sascha Hauer Signed-off-by: Ahmad Fatoum Link: https://lore.barebox.org/20230703142122.1522533-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer --- firmware/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'firmware') diff --git a/firmware/Makefile b/firmware/Makefile index 8d3bfb0752..d7f35853a4 100644 --- a/firmware/Makefile +++ b/firmware/Makefile @@ -49,7 +49,7 @@ filechk_fwbin = { \ echo "\#include " ;\ echo ".section .note.GNU-stack,\"\",%progbits" ;\ echo " .section $2,\"$3\"" ;\ - echo " .p2align $(ASM_LGPTR)" ;\ + echo " .p2align ASM_LGPTR" ;\ echo ".global _fw_$(FWSTR)_start" ;\ echo "_fw_$(FWSTR)_start:" ;\ echo "\#if $(FWNAME_EXISTS)" ;\ @@ -68,7 +68,7 @@ filechk_fwbin = { \ __fwbin_sha = { \ echo " .section .rodata.$(FWSTR).sha" ;\ - echo " .p2align $(ASM_LGPTR)" ;\ + echo " .p2align ASM_LGPTR" ;\ echo ".global _fw_$(FWSTR)_sha_start" ;\ echo "_fw_$(FWSTR)_sha_start:" ;\ echo " .incbin \"$(fwobjdir)/$(FWNAME).sha.bin\"" ;\ -- cgit v1.2.3