]> Git Repo - linux.git/commitdiff
kprobe/ftrace: fix build error due to bad function definition
authorLinus Torvalds <[email protected]>
Sat, 18 May 2024 02:17:55 +0000 (19:17 -0700)
committerLinus Torvalds <[email protected]>
Sat, 18 May 2024 02:17:55 +0000 (19:17 -0700)
Commit 1a7d0890dd4a ("kprobe/ftrace: bail out if ftrace was killed")
introduced a bad K&R function definition, which we haven't accepted in a
long long time.

Gcc seems to let it slide, but clang notices with the appropriate error:

  kernel/kprobes.c:1140:24: error: a function declaration without a prototype is deprecated in all >
   1140 | void kprobe_ftrace_kill()
        |                        ^
        |                         void

but this commit was apparently never in linux-next before it was sent
upstream, so it didn't get the appropriate build test coverage.

Fixes: 1a7d0890dd4a kprobe/ftrace: bail out if ftrace was killed
Cc: Stephen Brennan <[email protected]>
Cc: Masami Hiramatsu (Google) <[email protected]>
Cc: Guo Ren <[email protected]>
Cc: Steven Rostedt (Google) <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
kernel/kprobes.c

index f2cea3c80cb5893cff9c70876cc1cc2e30feb913..6a76a81000735e805981de4abf5035acedfb4537 100644 (file)
@@ -1137,7 +1137,7 @@ static int disarm_kprobe_ftrace(struct kprobe *p)
                ipmodify ? &kprobe_ipmodify_enabled : &kprobe_ftrace_enabled);
 }
 
-void kprobe_ftrace_kill()
+void kprobe_ftrace_kill(void)
 {
        kprobe_ftrace_disabled = true;
 }
This page took 0.061456 seconds and 4 git commands to generate.