From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Arnd Bergmann <arnd@arndb.de>, Ingo Molnar <mingo@kernel.org>,
Sasha Levin <sashal@kernel.org>,
tglx@linutronix.de, mingo@redhat.com, bp@alien8.de,
dave.hansen@linux.intel.com, x86@kernel.org,
jacob.jun.pan@linux.intel.com
Subject: [PATCH AUTOSEL 5.10 5/8] x86/irq: Define trace events conditionally
Date: Mon, 3 Mar 2025 11:32:08 -0500 [thread overview]
Message-ID: <20250303163211.3764282-5-sashal@kernel.org> (raw)
In-Reply-To: <20250303163211.3764282-1-sashal@kernel.org>
From: Arnd Bergmann <arnd@arndb.de>
[ Upstream commit 9de7695925d5d2d2085681ba935857246eb2817d ]
When both of X86_LOCAL_APIC and X86_THERMAL_VECTOR are disabled,
the irq tracing produces a W=1 build warning for the tracing
definitions:
In file included from include/trace/trace_events.h:27,
from include/trace/define_trace.h:113,
from arch/x86/include/asm/trace/irq_vectors.h:383,
from arch/x86/kernel/irq.c:29:
include/trace/stages/init.h:2:23: error: 'str__irq_vectors__trace_system_name' defined but not used [-Werror=unused-const-variable=]
Make the tracepoints conditional on the same symbosl that guard
their usage.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20250225213236.3141752-1-arnd@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
arch/x86/kernel/irq.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c
index ce904c89c6c70..3e01b80864031 100644
--- a/arch/x86/kernel/irq.c
+++ b/arch/x86/kernel/irq.c
@@ -22,8 +22,10 @@
#include <asm/desc.h>
#include <asm/traps.h>
+#if defined(CONFIG_X86_LOCAL_APIC) || defined(CONFIG_X86_THERMAL_VECTOR)
#define CREATE_TRACE_POINTS
#include <asm/trace/irq_vectors.h>
+#endif
DEFINE_PER_CPU_SHARED_ALIGNED(irq_cpustat_t, irq_stat);
EXPORT_PER_CPU_SYMBOL(irq_stat);
--
2.39.5
next prev parent reply other threads:[~2025-03-03 16:32 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-03 16:32 [PATCH AUTOSEL 5.10 1/8] ASoC: tas2770: Fix volume scale Sasha Levin
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 2/8] ASoC: tas2764: Fix power control mask Sasha Levin
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 3/8] ASoC: tas2764: Set the SDOUT polarity correctly Sasha Levin
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 4/8] fuse: don't truncate cached, mutated symlink Sasha Levin
2025-03-03 16:32 ` Sasha Levin [this message]
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 6/8] mptcp: safety check before fallback Sasha Levin
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 7/8] drm/nouveau: Do not override forced connector status Sasha Levin
2025-03-03 16:32 ` [PATCH AUTOSEL 5.10 8/8] block: fix 'kmem_cache of name 'bio-108' already exists' Sasha Levin
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=20250303163211.3764282-5-sashal@kernel.org \
--to=sashal@kernel.org \
--cc=arnd@arndb.de \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=jacob.jun.pan@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=mingo@redhat.com \
--cc=stable@vger.kernel.org \
--cc=tglx@linutronix.de \
--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