summaryrefslogtreecommitdiff
path: root/arch/arm/include
diff options
context:
space:
mode:
authorMarek BehĂșn <marek.behun@nic.cz>2021-05-20 13:23:52 +0200
committerTom Rini <trini@konsulko.com>2021-05-24 14:21:30 -0400
commit236f2ec43266cb4dabd320381498df6c9d80c82d (patch)
tree3e49eddacb53d4ed87a3417d1b861b2be18402e2 /arch/arm/include
parent9ce799aaba104a1f0d36bf84caec4c807fa31baa (diff)
treewide: Convert macro and uses of __section(foo) to __section("foo")
This commit does the same thing as Linux commit 33def8498fdd. Use a more generic form for __section that requires quotes to avoid complications with clang and gcc differences. Remove the quote operator # from compiler_attributes.h __section macro. Convert all unquoted __section(foo) uses to quoted __section("foo"). Also convert __attribute__((section("foo"))) uses to __section("foo") even if the __attribute__ has multiple list entry forms. Signed-off-by: Marek BehĂșn <marek.behun@nic.cz> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/secure.h6
-rw-r--r--arch/arm/include/asm/setup.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/arch/arm/include/asm/secure.h b/arch/arm/include/asm/secure.h
index 64e5582c1f2..c7b00be8e0b 100644
--- a/arch/arm/include/asm/secure.h
+++ b/arch/arm/include/asm/secure.h
@@ -4,8 +4,8 @@
#include <config.h>
#include <asm/global_data.h>
-#define __secure __attribute__ ((section ("._secure.text")))
-#define __secure_data __attribute__ ((section ("._secure.data")))
+#define __secure __section("._secure.text")
+#define __secure_data __section("._secure.data")
#ifndef __ASSEMBLY__
@@ -22,7 +22,7 @@ typedef struct secure_svc_tbl {
*/
#define DECLARE_SECURE_SVC(_name, _id, _fn) \
static const secure_svc_tbl_t __secure_svc_ ## _name \
- __attribute__((used, section("._secure_svc_tbl_entries"))) \
+ __used __section("._secure_svc_tbl_entries") \
= { \
.id = _id, \
.func = _fn }
diff --git a/arch/arm/include/asm/setup.h b/arch/arm/include/asm/setup.h
index 3a4e902af14..e0e2d7e3606 100644
--- a/arch/arm/include/asm/setup.h
+++ b/arch/arm/include/asm/setup.h
@@ -235,7 +235,7 @@ struct tagtable {
int (*parse)(const struct tag *);
};
-#define __tag __attribute__((unused, __section__(".taglist")))
+#define __tag __attribute__((unused)) __section(".taglist")
#define __tagtable(tag, fn) \
static struct tagtable __tagtable_##fn __tag = { tag, fn }