From: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-kernel@vger.kernel.org,
Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>,
Andreas Dilger <adilger.kernel@dilger.ca>,
Masahiro Yamada <yamada.masahiro@socionext.com>,
Michal Marek <michal.lkml@markovi.net>,
Steven Rostedt <rostedt@goodmis.org>,
Mauro Carvalho Chehab <mchehab+samsung@kernel.org>,
Olof Johansson <olof@lxom.net>,
Konstantin Ryabitsev <konstantin@linuxfoundation.org>,
"David S . Miller" <davem@davemloft.net>,
Andrey Ryabinin <aryabinin@virtuozzo.com>,
Kees Cook <keescook@chromium.org>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@kernel.org>,
Paul Lawrence <paullawrence@google.com>,
Sandipan Das <sandipan@linux.vnet.ibm.com>,
Andrey Konovalov <andreyknvl@google.com>,
David Woodhouse <dwmw2@infradead.org>,
Will
Subject: [PATCH v5 09/15] Compiler Attributes: remove uses of __attribute__ from compiler.h
Date: Thu, 20 Sep 2018 19:22:55 +0200 [thread overview]
Message-ID: <20180920172301.21868-10-miguel.ojeda.sandonis@gmail.com> (raw)
In-Reply-To: <20180920172301.21868-1-miguel.ojeda.sandonis@gmail.com>
Suggested-by: Nick Desaulniers <ndesaulniers@google.com>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Reviewed-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
---
include/linux/compiler.h | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/include/linux/compiler.h b/include/linux/compiler.h
index 17ee9165ca51..b5fb034fa6fa 100644
--- a/include/linux/compiler.h
+++ b/include/linux/compiler.h
@@ -23,8 +23,8 @@ void ftrace_likely_update(struct ftrace_likely_data *f, int val,
#define __branch_check__(x, expect, is_constant) ({ \
long ______r; \
static struct ftrace_likely_data \
- __attribute__((__aligned__(4))) \
- __attribute__((__section__("_ftrace_annotated_branch"))) \
+ __aligned(4) \
+ __section("_ftrace_annotated_branch") \
______f = { \
.data.func = __func__, \
.data.file = __FILE__, \
@@ -59,8 +59,8 @@ void ftrace_likely_update(struct ftrace_likely_data *f, int val,
({ \
int ______r; \
static struct ftrace_branch_data \
- __attribute__((__aligned__(4))) \
- __attribute__((__section__("_ftrace_branch"))) \
+ __aligned(4) \
+ __section("_ftrace_branch") \
______f = { \
.func = __func__, \
.file = __FILE__, \
@@ -146,7 +146,7 @@ void ftrace_likely_update(struct ftrace_likely_data *f, int val,
extern typeof(sym) sym; \
static const unsigned long __kentry_##sym \
__used \
- __attribute__((__section__("___kentry" "+" #sym ))) \
+ __section("___kentry" "+" #sym ) \
= (unsigned long)&sym;
#endif
@@ -287,7 +287,7 @@ unsigned long read_word_at_a_time(const void *addr)
* visible to the compiler.
*/
#define __ADDRESSABLE(sym) \
- static void * __attribute__((__section__(".discard.addressable"), used)) \
+ static void * __section(".discard.addressable") __used \
__PASTE(__addressable_##sym, __LINE__) = (void *)&sym;
/**
--
2.17.1
next prev parent reply other threads:[~2018-09-20 17:22 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-20 17:22 [PATCH v5 00/15] Compiler Attributes Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 01/15] Compiler Attributes: remove unused attributes Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 02/15] Compiler Attributes: always use the extra-underscores syntax Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 03/15] Compiler Attributes: remove unneeded tests Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 04/15] Compiler Attributes: homogenize __must_be_array Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 05/15] Compiler Attributes: remove unneeded sparse (__CHECKER__) tests Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 06/15] Compiler Attributes: add missing SPDX ID in compiler_types.h Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 07/15] Compiler Attributes: use feature checks instead of version checks Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 08/15] Compiler Attributes: KENTRY used twice the "used" attribute Miguel Ojeda
2018-09-20 17:22 ` Miguel Ojeda [this message]
2018-09-20 17:22 ` [PATCH v5 10/15] Compiler Attributes: add Doc/process/programming-language.rst Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 11/15] Compiler Attributes: add MAINTAINERS entry Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 12/15] Compiler Attributes: add support for __nonstring (gcc >= 8) Miguel Ojeda
2018-09-20 18:07 ` Nick Desaulniers
2018-09-20 20:08 ` Kees Cook
2018-09-30 11:16 ` Miguel Ojeda
2018-09-20 17:22 ` [PATCH v5 13/15] Compiler Attributes: enable -Wstringop-truncation on W=1 " Miguel Ojeda
2018-09-20 18:16 ` Nick Desaulniers
2018-09-20 19:52 ` Kees Cook
2018-09-30 11:17 ` Miguel Ojeda
2018-09-20 17:23 ` [PATCH v5 14/15] Compiler Attributes: auxdisplay: panel: use __nonstring Miguel Ojeda
2018-09-20 18:11 ` Nick Desaulniers
2018-09-20 17:23 ` [PATCH v5 15/15] Compiler Attributes: ext4: remove local __nonstring definition Miguel Ojeda
2018-09-20 18:13 ` Nick Desaulniers
2018-09-20 18:18 ` [PATCH v5 00/15] Compiler Attributes Nick Desaulniers
2018-09-24 14:36 ` Luc Van Oostenryck
2018-09-30 11:13 ` Miguel Ojeda
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180920172301.21868-10-miguel.ojeda.sandonis@gmail.com \
--to=miguel.ojeda.sandonis@gmail.com \
--cc=adilger.kernel@dilger.ca \
--cc=andreyknvl@google.com \
--cc=aryabinin@virtuozzo.com \
--cc=davem@davemloft.net \
--cc=dwmw2@infradead.org \
--cc=gregkh@linuxfoundation.org \
--cc=keescook@chromium.org \
--cc=konstantin@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mchehab+samsung@kernel.org \
--cc=michal.lkml@markovi.net \
--cc=mingo@kernel.org \
--cc=olof@lxom.net \
--cc=paullawrence@google.com \
--cc=rostedt@goodmis.org \
--cc=sandipan@linux.vnet.ibm.com \
--cc=tglx@linutronix.de \
--cc=yamada.masahiro@socionext.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).