aboutsummaryrefslogtreecommitdiff
path: root/include/common/bl_common.ld.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/common/bl_common.ld.h')
-rw-r--r--include/common/bl_common.ld.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/include/common/bl_common.ld.h b/include/common/bl_common.ld.h
index ab3391aa21..5147e37650 100644
--- a/include/common/bl_common.ld.h
+++ b/include/common/bl_common.ld.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2020, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2020-2021, ARM Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
@@ -105,10 +105,18 @@
* .rela.dyn needs to come after .data for the read-elf utility to parse
* this section correctly.
*/
+#if __aarch64__
+#define RELA_DYN_NAME .rela.dyn
+#define RELOC_SECTIONS_PATTERN *(.rela*)
+#else
+#define RELA_DYN_NAME .rel.dyn
+#define RELOC_SECTIONS_PATTERN *(.rel*)
+#endif
+
#define RELA_SECTION \
- .rela.dyn : ALIGN(STRUCT_ALIGN) { \
+ RELA_DYN_NAME : ALIGN(STRUCT_ALIGN) { \
__RELA_START__ = .; \
- *(.rela*) \
+ RELOC_SECTIONS_PATTERN \
__RELA_END__ = .; \
}