#
11642eb9 |
|
15-May-2023 |
Jiri Olsa <jolsa@kernel.org> |
selftests/bpf: Use un/load_bpf_testmod functions in tests Now that we have un/load_bpf_testmod helpers in testing_helpers.h, we can use it in other tests and save some lines. Acked-by: David Vernet <void@manifault.com> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Link: https://lore.kernel.org/r/20230515133756.1658301-7-jolsa@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
|
#
e697d8dc |
|
25-Oct-2022 |
Jiri Olsa <jolsa@kernel.org> |
selftests/bpf: Add kprobe_multi check to module attach test Adding test that makes sure the kernel module won't be removed if there's kprobe multi link defined on top of it. Acked-by: Song Liu <song@kernel.org> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Link: https://lore.kernel.org/r/20221025134148.3300700-8-jolsa@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
|
#
fa7f17d0 |
|
04-Oct-2021 |
Hou Tao <houtao1@huawei.com> |
bpf/selftests: Add test for writable bare tracepoint Add a writable bare tracepoint in bpf_testmod module, and trigger its calling when reading /sys/kernel/bpf_testmod with a specific buffer length. The reading will return the value in writable context if the early return flag is enabled in writable context. Signed-off-by: Hou Tao <houtao1@huawei.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Acked-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20211004094857.30868-4-hotforest@gmail.com
|
#
025bd7c7 |
|
10-Sep-2021 |
Song Liu <songliubraving@fb.com> |
selftests/bpf: Add test for bpf_get_branch_snapshot This test uses bpf_get_branch_snapshot from a fexit program. The test uses a target function (bpf_testmod_loop_test) and compares the record against kallsyms. If there isn't enough record matching kallsyms, the test fails. Signed-off-by: Song Liu <songliubraving@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Andrii Nakryiko <andrii@kernel.org> Acked-by: John Fastabend <john.fastabend@gmail.com> Link: https://lore.kernel.org/bpf/20210910183352.3151445-4-songliubraving@fb.com
|
#
a1c05c3b |
|
14-Apr-2021 |
Jiri Olsa <jolsa@kernel.org> |
selftests/bpf: Test that module can't be unloaded with attached trampoline Adding test to verify that once we attach module's trampoline, the module can't be unloaded. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20210414195147.1624932-7-jolsa@kernel.org
|
#
407be922 |
|
18-Jan-2021 |
Qais Yousef <qais.yousef@arm.com> |
selftests: bpf: Add a new test for bare tracepoints Reuse module_attach infrastructure to add a new bare tracepoint to check we can attach to it as a raw tracepoint. Signed-off-by: Qais Yousef <qais.yousef@arm.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Yonghong Song <yhs@fb.com> Link: https://lore.kernel.org/bpf/20210119122237.2426878-3-qais.yousef@arm.com
|
#
2e33f831 |
|
11-Dec-2020 |
Andrii Nakryiko <andrii@kernel.org> |
selftests/bpf: Add set_attach_target() API selftest for module target Add test for bpf_program__set_attach_target() API, validating it can find kernel module fentry target. Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Link: https://lore.kernel.org/bpf/20201211215825.3646154-3-andrii@kernel.org
|
#
1e38abef |
|
03-Dec-2020 |
Andrii Nakryiko <andrii@kernel.org> |
selftests/bpf: Add fentry/fexit/fmod_ret selftest for kernel module Add new selftest checking attachment of fentry/fexit/fmod_ret (and raw tracepoint ones for completeness) BPF programs to kernel module function. Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Link: https://lore.kernel.org/bpf/20201203204634.1325171-15-andrii@kernel.org
|