public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
* [for-next][PATCH 1/5] tracing: Fix function timing profiler to initialize hashtable
       [not found] <20241001214241.688116616@goodmis.org>
@ 2024-10-01 21:42 ` Steven Rostedt
  0 siblings, 0 replies; only message in thread
From: Steven Rostedt @ 2024-10-01 21:42 UTC (permalink / raw)
  To: linux-kernel
  Cc: Masami Hiramatsu, Mark Rutland, Mathieu Desnoyers, Andrew Morton,
	stable

From: "Masami Hiramatsu (Google)" <mhiramat@kernel.org>

Since the new fgraph requires to initialize fgraph_ops.ops.func_hash before
calling register_ftrace_graph(), initialize it with default (tracing all
functions) parameter.

Cc: stable@vger.kernel.org
Fixes: 5fccc7552ccb ("ftrace: Add subops logic to allow one ops to manage many")
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
---
 kernel/trace/ftrace.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
index 4c28dd177ca6..d2dd71d04b8a 100644
--- a/kernel/trace/ftrace.c
+++ b/kernel/trace/ftrace.c
@@ -883,6 +883,10 @@ static void profile_graph_return(struct ftrace_graph_ret *trace,
 }
 
 static struct fgraph_ops fprofiler_ops = {
+	.ops = {
+		.flags = FTRACE_OPS_FL_INITIALIZED,
+		INIT_OPS_HASH(fprofiler_ops.ops)
+	},
 	.entryfunc = &profile_graph_entry,
 	.retfunc = &profile_graph_return,
 };
-- 
2.45.2



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2024-10-01 21:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20241001214241.688116616@goodmis.org>
2024-10-01 21:42 ` [for-next][PATCH 1/5] tracing: Fix function timing profiler to initialize hashtable Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox