]> git.baikalelectronics.ru Git - kernel.git/commit
samples/bpf: move common-purpose trace functions to selftests
authorYonghong Song <yhs@fb.com>
Sun, 29 Apr 2018 05:28:13 +0000 (22:28 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Sun, 29 Apr 2018 15:45:54 +0000 (08:45 -0700)
commit534cb3f492ba9cdf315836b25401ce5d8aafe9e3
treeae98045b9d24ea60e1034b08200d74e762dde8bb
parent2baccfb5800e4dbfea3cb1f9c3859f8f3259fc1f
samples/bpf: move common-purpose trace functions to selftests

There is no functionality change in this patch. The common-purpose
trace functions, including perf_event polling and ksym lookup,
are moved from trace_output_user.c and bpf_load.c to
selftests/bpf/trace_helpers.c so that these function can
be reused later in selftests.

Acked-by: Alexei Starovoitov <ast@fb.com>
Signed-off-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
samples/bpf/Makefile
samples/bpf/bpf_load.c
samples/bpf/bpf_load.h
samples/bpf/offwaketime_user.c
samples/bpf/sampleip_user.c
samples/bpf/spintest_user.c
samples/bpf/trace_event_user.c
samples/bpf/trace_output_user.c
tools/testing/selftests/bpf/trace_helpers.c [new file with mode: 0644]
tools/testing/selftests/bpf/trace_helpers.h [new file with mode: 0644]