fix(st): mark INCBIN-generated sections as SHF_ALLOC
This is the same as rk3399 patch[1], add "a" option for sections
added to create stm32 file (containing BL2 and its DTB) in order to
properly link with clang.
This is still working with GCC.
[1]: 279cad8ed3 fix(rk3399): mark INCBIN-generated sections as SHF_ALLOC
Signed-off-by: Yann Gautier <yann.gautier@st.com>
Change-Id: Id5db55580c9c156aa6bf616c7c09a9307bca85f9
diff --git a/plat/st/stm32mp1/stm32mp1.S b/plat/st/stm32mp1/stm32mp1.S
index aee4f0e..a688f4d 100644
--- a/plat/st/stm32mp1/stm32mp1.S
+++ b/plat/st/stm32mp1/stm32mp1.S
@@ -1,11 +1,11 @@
/*
- * Copyright (c) 2016-2022, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2016-2025, Arm Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
-.section .bl2_image
+.section .bl2_image, "a"
.incbin BL2_BIN_PATH
-.section .dtb_image
+.section .dtb_image, "a"
.incbin DTB_BIN_PATH
diff --git a/plat/st/stm32mp2/aarch64/stm32mp2.S b/plat/st/stm32mp2/aarch64/stm32mp2.S
index 1866b8b..6c32972 100644
--- a/plat/st/stm32mp2/aarch64/stm32mp2.S
+++ b/plat/st/stm32mp2/aarch64/stm32mp2.S
@@ -1,11 +1,11 @@
/*
- * Copyright (c) 2023, STMicroelectronics - All Rights Reserved
+ * Copyright (c) 2023-2025, STMicroelectronics - All Rights Reserved
*
* SPDX-License-Identifier: BSD-3-Clause
*/
-.section .bl2_image
+.section .bl2_image, "a"
.incbin BL2_BIN_PATH
-.section .dtb_image
+.section .dtb_image, "a"
.incbin DTB_BIN_PATH