]> git.baikalelectronics.ru Git - kernel.git/commit
tools/bpf: add selftest in test_progs for bpf_send_signal() helper
authorYonghong Song <yhs@fb.com>
Thu, 23 May 2019 21:47:47 +0000 (14:47 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Fri, 24 May 2019 21:26:48 +0000 (23:26 +0200)
commit1ec77eca883a1c43b0042ed915bdd50869600bc4
treebe871dcf6d0496ed0093293e7cebb41a6b95ad0c
parent1f3b0a7c30b08b74b9df1226e2df59a5a577eb8e
tools/bpf: add selftest in test_progs for bpf_send_signal() helper

The test covered both nmi and tracepoint perf events.
  $ ./test_progs
  ...
  test_send_signal_tracepoint:PASS:tracepoint 0 nsec
  ...
  test_send_signal_common:PASS:tracepoint 0 nsec
  ...
  test_send_signal_common:PASS:perf_event 0 nsec
  ...
  test_send_signal:OK

Acked-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/testing/selftests/bpf/bpf_helpers.h
tools/testing/selftests/bpf/prog_tests/send_signal.c [new file with mode: 0644]
tools/testing/selftests/bpf/progs/test_send_signal_kern.c [new file with mode: 0644]