summaryrefslogtreecommitdiffstats
path: root/kernel/kprobes.c
diff options
context:
space:
mode:
authorSven Schnelle <svens@linux.ibm.com>2021-10-21 02:54:24 +0200
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2021-10-21 20:19:01 +0200
commite44e81c5b90f698025eadceb7eef8661eda117d5 (patch)
treeaf7785d8d3525cdf704f3f9831dffa22a97a0f2e /kernel/kprobes.c
parenttracing: use %ps format string to print symbols (diff)
downloadlinux-e44e81c5b90f698025eadceb7eef8661eda117d5.tar.xz
linux-e44e81c5b90f698025eadceb7eef8661eda117d5.zip
kprobes: convert tests to kunit
This converts the kprobes testcases to use the kunit framework. It adds a dependency on CONFIG_KUNIT, and the output will change to TAP: TAP version 14 1..1 # Subtest: kprobes_test 1..4 random: crng init done ok 1 - test_kprobe ok 2 - test_kprobes ok 3 - test_kretprobe ok 4 - test_kretprobes ok 1 - kprobes_test Note that the kprobes testcases are no longer run immediately after kprobes initialization, but as a late initcall when kunit is initialized. kprobes itself is initialized with an early initcall, so the order is still correct. Signed-off-by: Sven Schnelle <svens@linux.ibm.com> Acked-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel/kprobes.c')
-rw-r--r--kernel/kprobes.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/kernel/kprobes.c b/kernel/kprobes.c
index b62af9fc3607..4676627cb066 100644
--- a/kernel/kprobes.c
+++ b/kernel/kprobes.c
@@ -2581,9 +2581,6 @@ static int __init init_kprobes(void)
err = register_module_notifier(&kprobe_module_nb);
kprobes_initialized = (err == 0);
-
- if (!err)
- init_test_probes();
return err;
}
early_initcall(init_kprobes);