From: Mikael Beckius via lttng-dev <lttng-dev@lists.lttng.org>
To: lttng-dev@lists.lttng.org
Subject: [lttng-dev] [PATCH] lttng: Add CONFIG_PREEMPTIRQ_TRACEPOINTS as a preemptirq condition
Date: Thu, 20 Oct 2022 11:13:21 +0200 [thread overview]
Message-ID: <20221020091321.27945-1-mikael.beckius@windriver.com> (raw)
Signed-off-by: Mikael Beckius <mikael.beckius@windriver.com>
---
include/instrumentation/events/preemptirq.h | 8 +++++---
src/probes/Kbuild | 4 ++--
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/include/instrumentation/events/preemptirq.h b/include/instrumentation/events/preemptirq.h
index 80bbbac6..2b991dee 100644
--- a/include/instrumentation/events/preemptirq.h
+++ b/include/instrumentation/events/preemptirq.h
@@ -1,5 +1,5 @@
/* SPDX-License-Identifier: GPL-2.0-only */
-#ifdef CONFIG_PREEMPTIRQ_EVENTS
+#if defined(CONFIG_PREEMPTIRQ_TRACEPOINTS) || (CONFIG_PREEMPTIRQ_EVENTS)
#undef TRACE_SYSTEM
#define TRACE_SYSTEM preemptirq
@@ -13,7 +13,9 @@
#include <lttng/tracepoint-event.h>
/*
- * The preemptirq probe is built when CONFIG_PREEMPTIRQ_EVENTS is defined.
+ * The preemptirq probe is built when CONFIG_PREEMPTIRQ_TRACEPOINTS
+ * is defined or when CONFIG_PREEMPTIRQ_EVENTS is defined on kernels
+ * older than 4.19.
*/
LTTNG_TRACEPOINT_EVENT_CLASS(preemptirq_template,
@@ -97,4 +99,4 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE_MAP(preemptirq_template, preempt_enable,
/* This part must be outside protection */
#include <lttng/define_trace.h>
-#endif /* CONFIG_PREEMPTIRQ_EVENTS */
+#endif /* CONFIG_PREEMPTIRQ_TRACEPOINTS */
diff --git a/src/probes/Kbuild b/src/probes/Kbuild
index aa002534..03468d16 100644
--- a/src/probes/Kbuild
+++ b/src/probes/Kbuild
@@ -284,8 +284,8 @@ ifneq ($(CONFIG_KRETPROBES),)
obj-$(CONFIG_LTTNG) += lttng-kretprobes.o
endif # CONFIG_KRETPROBES
-ifneq ($(CONFIG_PREEMPTIRQ_EVENTS),)
+ifneq ($(or $(CONFIG_PREEMPTIRQ_TRACEPOINTS),$(CONFIG_PREEMPTIRQ_EVENTS)),)
obj-$(CONFIG_LTTNG) += lttng-probe-preemptirq.o
-endif # CONFIG_PREEMPTIRQ_EVENTS
+endif # CONFIG_PREEMPTIRQ_TRACEPOINTS
# vim:syntax=make
--
2.34.1
_______________________________________________
lttng-dev mailing list
lttng-dev@lists.lttng.org
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
reply other threads:[~2022-10-20 14:54 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20221020091321.27945-1-mikael.beckius@windriver.com \
--to=lttng-dev@lists.lttng.org \
--cc=mikael.beckius@windriver.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 read-only IMAP folder(s) and NNTP newsgroup(s).