Skip to contentSkip to conversation

ftrace/nds32: Update the proto for ftrace_trace_function to match ftrace_stub

GIT PULL Merged Steven Rostedt 2 participants 2 messages Oct 27, 2021 ftrace

lore
Share & tools
lore

Steven Rostedt

author maintainer
#0 lore raw

Linus,

Fix nds32le build when DYNAMIC_FTRACE is disabled

A randconfig found that nds32le architecture fails to build due to a prototype mismatch between a ftrace function pointer and the function it was to be assigned to. That function pointer prototype missed being updated when all the ftrace callbacks were updated.

Please pull the latest trace-v5.15-rc6 tree, which can be found at:

git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git
trace-v5.15-rc6

Tag SHA1: 832b54f439525d3b853698ac77fa1be977452a3b Head SHA1: 4e84dc47bb48accbbeeba4e6bb3f31aa7895323c

Steven Rostedt (VMware) (1):
ftrace/nds32: Update the proto for ftrace_trace_function to match ftrace_stub

----

 arch/nds32/kernel/ftrace.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---------------------------
commit 4e84dc47bb48accbbeeba4e6bb3f31aa7895323c
Author: Steven Rostedt (VMware) <[email protected]>
Date:   Wed Oct 27 12:51:01 2021 -0400

ftrace/nds32: Update the proto for ftrace_trace_function to match ftrace_stub

The ftrace callback prototype was changed to pass a special ftrace_regs instead of pt_regs as the last parameter, but the static ftrace for nds32 missed updating ftrace_trace_function and this caused a warning when compared to ftrace_stub:

../arch/nds32/kernel/ftrace.c: In function '_mcount':
../arch/nds32/kernel/ftrace.c:24:35: error: comparison of distinct pointer types lacks a cast [-Werror]
24 | if (ftrace_trace_function != ftrace_stub)
| ^~

Cc Ingo Molnar <[email protected]>
Cc Andrew Morton <[email protected]>
Cc Nick Hu <[email protected]>
Cc Greentime Hu <[email protected]>
Cc Vincent Chen <[email protected]>
Cc Masami Hiramatsu <[email protected]>
Cc Peter Zijlstra <[email protected]>
Fixes d19ad0775dcd6 ("ftrace: Have the callbacks receive a struct ftrace_regs instead of pt_regs")
arch/nds32/kernel/ftrace.c +1 -1
index 0e23e3a8df6b..d55b73b18149 100644
@@ -6,7 +6,7 @@
 
 #ifndef CONFIG_DYNAMIC_FTRACE
 extern void (*ftrace_trace_function)(unsigned long, unsigned long,
-				     struct ftrace_ops*, struct pt_regs*);
+				     struct ftrace_ops*, struct ftrace_regs*);
 extern void ftrace_graph_caller(void);
 
 noinline void __naked ftrace_stub(unsigned long ip, unsigned long parent_ip,
merge bot Merged
#1 lore raw
The pull request you sent on Wed, 27 Oct 2021 13:28:13 -0400:

The pull request you sent on Wed, 27 Oct 2021 13:28:13 -0400:

Quoted 1 line

git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git trace-v5.15-rc6

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/1fc596a56b334f4d593a2b49e5ff55af6aaa0816

Thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html