[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231107181057.334c815f@gandalf.local.home>
Date: Tue, 7 Nov 2023 18:10:57 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: Ankur Arora <ankur.a.arora@...cle.com>
Cc: linux-kernel@...r.kernel.org, tglx@...utronix.de,
peterz@...radead.org, torvalds@...ux-foundation.org,
paulmck@...nel.org, linux-mm@...ck.org, x86@...nel.org,
akpm@...ux-foundation.org, luto@...nel.org, bp@...en8.de,
dave.hansen@...ux.intel.com, hpa@...or.com, mingo@...hat.com,
juri.lelli@...hat.com, vincent.guittot@...aro.org,
willy@...radead.org, mgorman@...e.de, jon.grimm@....com,
bharata@....com, raghavendra.kt@....com,
boris.ostrovsky@...cle.com, konrad.wilk@...cle.com,
jgross@...e.com, andrew.cooper3@...rix.com, mingo@...nel.org,
bristot@...nel.org, mathieu.desnoyers@...icios.com,
geert@...ux-m68k.org, glaubitz@...sik.fu-berlin.de,
anton.ivanov@...bridgegreys.com, mattst88@...il.com,
krypton@...ich-teichert.org, David.Laight@...LAB.COM,
richard@....at, mjguzik@...il.com
Subject: Re: [RFC PATCH 03/86] Revert "ftrace: Use preemption model
accessors for trace header printout"
On Tue, 7 Nov 2023 13:56:49 -0800
Ankur Arora <ankur.a.arora@...cle.com> wrote:
> This reverts commit 089c02ae2771a14af2928c59c56abfb9b885a8d7.
I rather not revert this.
If user space can decided between various version of preemption, then the
trace should reflect that. At least state what the preemption model was when
a trace started, or currently is.
That is, the model may not be "static" per boot. Anyway, the real change here should be:
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 7b4b1fcd6f93..2553c4efca15 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -2208,14 +2208,6 @@ static inline void cond_resched_rcu(void)
#endif
}
-#ifdef CONFIG_PREEMPT_DYNAMIC
-
-extern bool preempt_model_none(void);
-extern bool preempt_model_voluntary(void);
-extern bool preempt_model_full(void);
-
-#else
-
static inline bool preempt_model_none(void)
{
return IS_ENABLED(CONFIG_PREEMPT_NONE);
@@ -2229,8 +2221,6 @@ static inline bool preempt_model_full(void)
return IS_ENABLED(CONFIG_PREEMPT);
}
-#endif
-
static inline bool preempt_model_rt(void)
{
return IS_ENABLED(CONFIG_PREEMPT_RT);
Then this way we can decided to make it runtime dynamic, we don't need to
fiddle with the tracing code again.
-- Steve
Powered by blists - more mailing lists