aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2015-04-28 12:48:39 +0200
committerChristopher Li <sparse@chrisli.org>2015-06-11 17:38:47 -0700
commit60432109a5cb0687d255cd0d022ae7711e6340f5 (patch)
treef523277b78bd8c4033cc3ca7f9fd4f0c5cf76e4a
parentefd34fafe5cba2eedfe889e49698f5eb119547bd (diff)
downloadsparse-60432109a5cb0687d255cd0d022ae7711e6340f5.tar.gz
sparse/parse.c: ignore hotpatch attribute
gcc knows about a new "hotpatch" attribute which sparse can safely ignore, since it modifies only which code will be generated just like the "no_instrument_function" attribute. The gcc hotpatch feature patch: https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=11762b8363737591bfb9c66093bc2edf289b917f Currently the Linux kernel makes use of this attribute: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=61f552141c9c0e88b3fdc7046265781ffd8fa68a Without this patch sparse will emit warnings like "error: attribute 'hotpatch': unknown attribute" Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Christopher Li <sparse@chrisli.org>
-rw-r--r--parse.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/parse.c b/parse.c
index b43d6835..8afae73d 100644
--- a/parse.c
+++ b/parse.c
@@ -540,6 +540,8 @@ const char *ignored_attributes[] = {
"__gnu_inline__",
"hot",
"__hot__",
+ "hotpatch",
+ "__hotpatch__",
"leaf",
"__leaf__",
"l1_text",