From 6d64d927a28212801851f99ab84eda840289a9e9 Mon Sep 17 00:00:00 2001 From: Andrii Nakryiko Date: Thu, 12 Mar 2020 18:54:43 -0700 Subject: [PATCH] vmtests: enable previously failing kprobe selftests With fixes in selftests, these tests should now pass. Also add ability to add comments to blacklist/whitelist to explain why certain test is disabled. Signed-off-by: Andrii Nakryiko --- .../vmtest/configs/blacklist/BLACKLIST-5.5.0 | 24 +++++++++++-------- .../vmtest/configs/blacklist/BLACKLIST-latest | 6 ++--- travis-ci/vmtest/run_selftests.sh | 4 ++-- 3 files changed, 18 insertions(+), 16 deletions(-) diff --git a/travis-ci/vmtest/configs/blacklist/BLACKLIST-5.5.0 b/travis-ci/vmtest/configs/blacklist/BLACKLIST-5.5.0 index d2b8523..3017012 100644 --- a/travis-ci/vmtest/configs/blacklist/BLACKLIST-5.5.0 +++ b/travis-ci/vmtest/configs/blacklist/BLACKLIST-5.5.0 @@ -1,12 +1,16 @@ -attach_multi -attach_probe -bpf_tcp_ca -fexit_bpf2bpf -link_pinning -perf_branches -perf_buffer +bpf_tcp_ca # STRUCT_OPS is missing +cgroup_attach_multi # BPF_F_REPLACE_PROG missing +fentry_fexit # bpf_prog_test_tracing missing +fentry_test # bpf_prog_test_tracing missing +fexit_bpf2bpf # freplace is missing +fexit_test # bpf_prog_test_tracing missing +link_pinning # bpf_link is missing +modify_return # fmod_ret is missing +ns_current_pid_tgid # bpf_get_ns_current_pid_tgid() helper is missing +perf_branches # bpf_read_branch_records() helper is missing select_reuseport -send_signal +send_signal # flaky skb_ctx -sockmap_listen -test_global_funcs +sockmap_listen # flaky +test_global_funcs # kernel doesn't support BTF linkage=global on FUNCs +xdp_bpf2bpf # freplace is missing diff --git a/travis-ci/vmtest/configs/blacklist/BLACKLIST-latest b/travis-ci/vmtest/configs/blacklist/BLACKLIST-latest index b4b4d40..f7a7dc6 100644 --- a/travis-ci/vmtest/configs/blacklist/BLACKLIST-latest +++ b/travis-ci/vmtest/configs/blacklist/BLACKLIST-latest @@ -1,4 +1,2 @@ -attach_probe -perf_buffer -send_signal -sockmap_listen +send_signal # flaky +sockmap_listen # flaky diff --git a/travis-ci/vmtest/run_selftests.sh b/travis-ci/vmtest/run_selftests.sh index 0d19926..649511a 100755 --- a/travis-ci/vmtest/run_selftests.sh +++ b/travis-ci/vmtest/run_selftests.sh @@ -21,12 +21,12 @@ test_verifier() { configs_path='libbpf/travis-ci/vmtest/configs' blacklist_path="$configs_path/blacklist/BLACKLIST-${KERNEL}" if [[ -s "${blacklist_path}" ]]; then - BLACKLIST=$(cat "${blacklist_path}" | tr '\n' ',') + BLACKLIST=$(cat "${blacklist_path}" | cut -d'#' -f1 | tr -s '[:space:]' ',') fi whitelist_path="$configs_path/whitelist/WHITELIST-${KERNEL}" if [[ -s "${whitelist_path}" ]]; then - WHITELIST=$(cat "${whitelist_path}" | tr '\n' ',') + WHITELIST=$(cat "${whitelist_path}" | cut -d'#' -f1 | tr -s '[:space:]' ',') fi cd libbpf/selftests/bpf