]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/bpf: Add C tests for reference tracking
authorJoe Stringer <joe@wand.net.nz>
Tue, 2 Oct 2018 20:35:40 +0000 (13:35 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 3 Oct 2018 00:53:48 +0000 (02:53 +0200)
commit7858b746f149b6300893b67a031da627e1561a7b
treeb1d64d98319f474b264d38a1d3b71c6c4726a73c
parent8febfa736b81a20440276ed7fc6e637d9b3c6e2b
selftests/bpf: Add C tests for reference tracking

Add some tests that demonstrate and test the balanced lookup/free
nature of socket lookup. Section names that start with "fail" represent
programs that are expected to fail verification; all others should
succeed.

Signed-off-by: Joe Stringer <joe@wand.net.nz>
Acked-by: Alexei Starovoitov <ast@kernel.org>
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_sk_lookup_kern.c [new file with mode: 0644]