summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/test_progs.h
diff options
context:
space:
mode:
authorKui-Feng Lee <thinker.li@gmail.com>2024-08-14 22:32:50 -0700
committerMartin KaFai Lau <martin.lau@kernel.org>2024-08-15 11:33:49 -0700
commitf5281aacec856e7e0beb643d74122595fc1fb4be (patch)
tree399d8ddd414876c8026e17788dc28323f256772e /tools/testing/selftests/bpf/test_progs.h
parentf52403b6bfea6994b017c58367aee9acdb9d9fd4 (diff)
selftests/bpf: Add the traffic monitor option to test_progs.
Add option '-m' to test_progs to accept names and patterns of test cases. This option will be used later to enable traffic monitor that capture network packets generated by test cases. Acked-by: Stanislav Fomichev <sdf@fomichev.me> Signed-off-by: Kui-Feng Lee <thinker.li@gmail.com> Link: https://lore.kernel.org/r/20240815053254.470944-3-thinker.li@gmail.com Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Diffstat (limited to 'tools/testing/selftests/bpf/test_progs.h')
-rw-r--r--tools/testing/selftests/bpf/test_progs.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/testing/selftests/bpf/test_progs.h b/tools/testing/selftests/bpf/test_progs.h
index cb9d6d46826b..966011eb7ec8 100644
--- a/tools/testing/selftests/bpf/test_progs.h
+++ b/tools/testing/selftests/bpf/test_progs.h
@@ -74,6 +74,7 @@ struct subtest_state {
int error_cnt;
bool skipped;
bool filtered;
+ bool should_tmon;
FILE *stdout_saved;
};
@@ -98,6 +99,7 @@ struct test_state {
struct test_env {
struct test_selector test_selector;
struct test_selector subtest_selector;
+ struct test_selector tmon_selector;
bool verifier_stats;
bool debug;
enum verbosity verbosity;