diff options
author | Andrii Nakryiko <andrii@kernel.org> | 2020-12-03 12:46:26 -0800 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2020-12-03 17:38:20 -0800 |
commit | 9f7fa225894c7fcb014f3699a402fcc4d896cb1c (patch) | |
tree | edf41331c46aa34ac41b9b1545b112575a112edc /tools/testing/selftests/bpf/test_progs.h | |
parent | 4f33a53d56000cfa67e2e4e8a5dac08f084a979b (diff) |
selftests/bpf: Add bpf_testmod kernel module for testing
Add bpf_testmod module, which is conceptually out-of-tree module and provides
ways for selftests/bpf to test various kernel module-related functionality:
raw tracepoint, fentry/fexit/fmod_ret, etc. This module will be auto-loaded by
test_progs test runner and expected by some of selftests to be present and
loaded.
Pahole currently isn't able to generate BTF for static functions in kernel
modules, so make sure traced function is global.
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Martin KaFai Lau <kafai@fb.com>
Link: https://lore.kernel.org/bpf/20201203204634.1325171-7-andrii@kernel.org
Diffstat (limited to 'tools/testing/selftests/bpf/test_progs.h')
-rw-r--r-- | tools/testing/selftests/bpf/test_progs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/bpf/test_progs.h b/tools/testing/selftests/bpf/test_progs.h index d6b14853f3bc..115953243f62 100644 --- a/tools/testing/selftests/bpf/test_progs.h +++ b/tools/testing/selftests/bpf/test_progs.h @@ -66,6 +66,7 @@ struct test_env { enum verbosity verbosity; bool jit_enabled; + bool has_testmod; bool get_test_cnt; bool list_test_names; |