]> git.baikalelectronics.ru Git - kernel.git/commit
tools/bpf: add a bpf selftest for stacktrace
authorYonghong Song <yhs@fb.com>
Thu, 4 Jan 2018 21:55:04 +0000 (13:55 -0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Sat, 6 Jan 2018 22:52:23 +0000 (23:52 +0100)
commit88430c8e8b83e82c975139647e6d6782f2be557b
tree33efbd17272bf7e54425103a21e7b31856bc7683
parent624999a37f102297425dfa5c31a1296971fddab2
tools/bpf: add a bpf selftest for stacktrace

Added a bpf selftest in test_progs at tools directory for stacktrace.
The test will populate a hashtable map and a stacktrace map
at the same time with the same key, stackid.
The user space will compare both maps, using BPF_MAP_LOOKUP_ELEM
command and BPF_MAP_GET_NEXT_KEY command, to ensure that both have
the same set of keys.

Signed-off-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/testing/selftests/bpf/Makefile
tools/testing/selftests/bpf/test_progs.c
tools/testing/selftests/bpf/test_stacktrace_map.c [new file with mode: 0644]