]> Git Repo - J-linux.git/commitdiff
parisc/ftrace: Fix function graph tracing disablement
authorJosh Poimboeuf <[email protected]>
Wed, 2 Oct 2024 21:32:04 +0000 (14:32 -0700)
committerHelge Deller <[email protected]>
Sat, 16 Nov 2024 21:55:56 +0000 (22:55 +0100)
Due to an apparent copy-paste bug, the parisc implementation of
ftrace_disable_ftrace_graph_caller() doesn't actually do anything.
It enables the (already-enabled) static key rather than disabling it.

The result is that after function graph tracing has been "disabled", any
subsequent (non-graph) function tracing will inadvertently also enable
the slow fgraph return address hijacking.

Fixes: 98f2926171ae ("parisc/ftrace: use static key to enable/disable function graph tracer")
Cc: [email protected] # 5.16+
Signed-off-by: Josh Poimboeuf <[email protected]>
Signed-off-by: Helge Deller <[email protected]>
arch/parisc/kernel/ftrace.c

index c91f9c2e61ed25e605dacd34a6f270282c022e34..f8d08eab7db8b051ddd41afc2535c88907eb8a0d 100644 (file)
@@ -87,7 +87,7 @@ int ftrace_enable_ftrace_graph_caller(void)
 
 int ftrace_disable_ftrace_graph_caller(void)
 {
-       static_key_enable(&ftrace_graph_enable.key);
+       static_key_disable(&ftrace_graph_enable.key);
        return 0;
 }
 #endif
This page took 0.048234 seconds and 4 git commands to generate.