From: "tip-bot2 for Uros Bizjak" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: kernel test robot <lkp@intel.com>,
Luc Van Oostenryck <luc.vanoostenryck@gmail.com>,
Uros Bizjak <ubizjak@gmail.com>, Ingo Molnar <mingo@kernel.org>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: x86/percpu] x86/percpu: Avoid sparse warning with cast to named address space
Date: Mon, 11 Dec 2023 12:06:17 -0000 [thread overview]
Message-ID: <170229637722.398.17541780401553649834.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20231204210320.114429-3-ubizjak@gmail.com>
The following commit has been merged into the x86/percpu branch of tip:
Commit-ID: 3a1d3829e193c091475ceab481c5f8deab385023
Gitweb: https://git.kernel.org/tip/3a1d3829e193c091475ceab481c5f8deab385023
Author: Uros Bizjak <ubizjak@gmail.com>
AuthorDate: Mon, 04 Dec 2023 22:02:31 +01:00
Committer: Ingo Molnar <mingo@kernel.org>
CommitterDate: Mon, 11 Dec 2023 11:47:15 +01:00
x86/percpu: Avoid sparse warning with cast to named address space
Teach sparse about __seg_fs and __seg_gs named address space
qualifiers to to avoid warnings about unexpected keyword at
the end of cast operator.
Reported-by: kernel test robot <lkp@intel.com>
Acked-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Uros Bizjak <ubizjak@gmail.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20231204210320.114429-3-ubizjak@gmail.com
Closes: https://lore.kernel.org/oe-kbuild-all/202310080853.UhMe5iWa-lkp@intel.com/
---
arch/x86/include/asm/percpu.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/x86/include/asm/percpu.h b/arch/x86/include/asm/percpu.h
index 3859aba..e56a378 100644
--- a/arch/x86/include/asm/percpu.h
+++ b/arch/x86/include/asm/percpu.h
@@ -36,6 +36,11 @@
#ifdef CONFIG_CC_HAS_NAMED_AS
+#ifdef __CHECKER__
+#define __seg_gs __attribute__((address_space(__seg_gs)))
+#define __seg_fs __attribute__((address_space(__seg_fs)))
+#endif
+
#ifdef CONFIG_X86_64
#define __percpu_seg_override __seg_gs
#else
next prev parent reply other threads:[~2023-12-11 12:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-04 21:02 [PATCH -tip v3 1/3] x86/percpu: Fix "const_pcpu_hot" version generation failure Uros Bizjak
2023-12-04 21:02 ` [PATCH -tip v3 2/3] x86/traps: Use current_top_of_stack() helper in traps.c Uros Bizjak
2023-12-11 12:06 ` [tip: x86/percpu] " tip-bot2 for Uros Bizjak
2023-12-04 21:02 ` [PATCH -tip v3 3/3] x86/percpu: Avoid sparse warning with cast to named address space Uros Bizjak
2023-12-05 0:21 ` Luc Van Oostenryck
2023-12-11 12:06 ` tip-bot2 for Uros Bizjak [this message]
2023-12-11 12:06 ` [tip: x86/percpu] x86/percpu: Fix "const_pcpu_hot" version generation failure tip-bot2 for Uros Bizjak
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=170229637722.398.17541780401553649834.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=lkp@intel.com \
--cc=luc.vanoostenryck@gmail.com \
--cc=mingo@kernel.org \
--cc=ubizjak@gmail.com \
--cc=x86@kernel.org \
/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).