function_graph: Fix missing FGRAPH_ENTRY_ARGS() call in print_graph_retval()
PATCH 1/1 function_graph: Fix missing FGRAPH_ENTRY_ARGS() call in print_graph_retval()
From: Donglin Peng <[email protected]>
Call FGRAPH_ENTRY_ARGS(entry) to retrieve the correct arguments pointer when displaying function parameters in print_graph_retval().
Fixes f83ac7544fbf ("function_graph: Enable funcgraph-args and funcgraph-retaddr to work simultaneously")
Signed-off-by Donglin Peng <[email protected]>
--- kernel/trace/trace_functions_graph.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/trace/trace_functions_graph.c +1 -1
@@ -901,7 +901,7 @@ static void print_graph_retval(struct trace_seq *s, struct ftrace_graph_ent_entrtrace_seq_printf (s,"%ps" , func);if (args_size >=FTRACE_REGS_MAX_ARGS *sizeof (long )) { -print_function_args (s, entry->args, (unsigned long )func); +print_function_args (s,FGRAPH_ENTRY_ARGS (entry), (unsigned long )func);trace_seq_putc (s,';' ); }else trace_seq_puts (s,"();" );
Signature · 1 line
2.34.1
Quoted 7 lines · On Sun, 11 Jan 2026 22:33:18 +0800 Donglin Peng <[email protected]> wrote:
From: Donglin Peng <[email protected]>
Call
FGRAPH_ENTRY_ARGS(entry)to retrieve the correct arguments pointer when displaying function parameters inprint_graph_retval().Fixes f83ac7544fbf ("function_graph: Enable funcgraph-args and funcgraph-retaddr to work simultaneously")Signed-off-by Donglin Peng <[email protected]>
Looks good to me. (other print_function_args() using this macro)
Thanks!
Quoted 20 lines
--- kernel/trace/trace_functions_graph.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)kernel/trace/trace_functions_graph.c +1
-1@@ -901,7 +901,7 @@ static void print_graph_retval(struct trace_seq *s, struct ftrace_graph_ent_entrtrace_seq_printf (s,"%ps" , func);if (args_size >=FTRACE_REGS_MAX_ARGS *sizeof (long )) { -print_function_args (s, entry->args, (unsigned long )func); +print_function_args (s,FGRAPH_ENTRY_ARGS (entry), (unsigned long )func);trace_seq_putc (s,';' ); }else trace_seq_puts (s,"();" );Signature · 1 line
2.34.1
Signature · 1 line
Masami Hiramatsu (Google) <[email protected]>