Home
last modified time | relevance | path

Searched refs:test_case (Results 1 – 25 of 51) sorted by relevance

123

/linux-6.15/tools/testing/selftests/bpf/prog_tests/
H A Dmigrate_reuseport.c211 test_case->link = NULL; in pass_ack()
225 &test_case->addr, &test_case->addrlen); in start_servers()
228 test_case->servers[i] = socket(test_case->family, SOCK_STREAM, in start_servers()
240 test_case->addrlen); in start_servers()
254 &test_case->addrlen); in start_servers()
259 if (test_case->fastopen) { in start_servers()
284 test_case->clients[i] = socket(test_case->family, SOCK_STREAM, in start_clients()
470 if (test_case->fastopen) { in run_test()
482 if (test_case->drop_ack) { in run_test()
518 if (test_case->link) { in run_test()
[all …]
H A Dcore_reloc.c1021 test_case = &test_case_copy; in run_core_reloc_tests()
1034 if (!test_case->btf_src_file || test_case->run_btfgen_fails) { in run_core_reloc_tests()
1044 test_case->bpf_obj_file); in run_core_reloc_tests()
1051 if (test_case->setup) { in run_core_reloc_tests()
1052 err = test_case->setup(test_case); in run_core_reloc_tests()
1057 if (test_case->btf_src_file) { in run_core_reloc_tests()
1077 if (!test_case->fails) in run_core_reloc_tests()
1096 if (test_case->input_len) in run_core_reloc_tests()
1097 memcpy(data->in, test_case->input, test_case->input_len); in run_core_reloc_tests()
1105 if (test_case->trigger) { in run_core_reloc_tests()
[all …]
H A Dtcp_custom_syncookie.c92 static void create_connection(struct test_tcp_custom_syncookie_case *test_case) in create_connection() argument
96 server = start_server(test_case->family, test_case->type, test_case->addr, 0, 0); in create_connection()
H A Dcore_extern.c23 static struct test_case { struct
131 struct test_case *t = &test_cases[i]; in test_core_extern()
H A Dxdp_bonding.c671 struct bond_test_case *test_case = &bond_test_cases[i]; in serial_test_xdp_bonding() local
673 if (test__start_subtest(test_case->name)) in serial_test_xdp_bonding()
676 test_case->mode, in serial_test_xdp_bonding()
677 test_case->xmit_policy); in serial_test_xdp_bonding()
/linux-6.15/lib/kunit/
H A Dtest.c133 struct kunit_case *test_case; in kunit_suite_num_test_cases() local
236 struct kunit_case *test_case) in kunit_test_case_num() argument
242 if (tc == test_case) in kunit_test_case_num()
398 test_case->run_case(test); in kunit_run_case_internal()
426 struct kunit_case *test_case; member
434 struct kunit_case *test_case = ctx->test_case; in kunit_try_run_case() local
519 struct kunit_case *test_case, in kunit_run_case_catch_errors() argument
533 context.test_case = test_case; in kunit_run_case_catch_errors()
604 struct kunit_case *test_case; in kunit_run_tests() local
626 kunit_init_test(&test, test_case->name, test_case->log); in kunit_run_tests()
[all …]
H A Ddebugfs.c68 struct kunit_case *test_case; in debugfs_print_results() local
84 kunit_suite_for_each_test_case(suite, test_case) in debugfs_print_results()
85 debugfs_print_result(seq, test_case->log); in debugfs_print_results()
170 struct kunit_case *test_case; in kunit_debugfs_create_suite() local
190 kunit_suite_for_each_test_case(suite, test_case) { in kunit_debugfs_create_suite()
196 test_case->log = stream; in kunit_debugfs_create_suite()
217 string_stream_destroy(test_case->log); in kunit_debugfs_create_suite()
218 test_case->log = NULL; in kunit_debugfs_create_suite()
224 struct kunit_case *test_case; in kunit_debugfs_destroy_suite() local
228 kunit_suite_for_each_test_case(suite, test_case) in kunit_debugfs_destroy_suite()
[all …]
H A Dexecutor.c117 struct kunit_case *filtered, *test_case; in kunit_filter_glob_tests() local
120 kunit_suite_for_each_test_case(suite, test_case) { in kunit_filter_glob_tests()
121 if (!test_glob || glob_match(test_glob, test_case->name)) in kunit_filter_glob_tests()
139 kunit_suite_for_each_test_case(suite, test_case) { in kunit_filter_glob_tests()
140 if (!test_glob || glob_match(test_glob, test_case->name)) in kunit_filter_glob_tests()
141 filtered[n++] = *test_case; in kunit_filter_glob_tests()
292 struct kunit_case *test_case; in kunit_exec_list_tests() local
304 kunit_suite_for_each_test_case((*suites), test_case) { in kunit_exec_list_tests()
305 pr_info("%s.%s\n", (*suites)->name, test_case->name); in kunit_exec_list_tests()
307 kunit_print_attr((void *)test_case, true, 0); in kunit_exec_list_tests()
H A Dattributes.c401 struct kunit_case *filtered, *test_case; in kunit_filter_attr_tests() local
411 kunit_suite_for_each_test_case(suite, test_case) { n++; } in kunit_filter_attr_tests()
433 kunit_suite_for_each_test_case(suite, test_case) { in kunit_filter_attr_tests()
434 test_val = filter.attr->get_attr((void *) test_case, true); in kunit_filter_attr_tests()
435 test_result = filter.attr->filter(filter.attr->get_attr(test_case, true), in kunit_filter_attr_tests()
457 filtered[n++] = *test_case; in kunit_filter_attr_tests()
459 test_case->status = KUNIT_SKIPPED; in kunit_filter_attr_tests()
460 filtered[n++] = *test_case; in kunit_filter_attr_tests()
/linux-6.15/drivers/virt/nitro_enclaves/
H A Dne_misc_dev_test.c123 struct ne_phys_regions_test *test_case = &phys_regions_test_cases[i]; in ne_misc_dev_test_merge_phys_contig_memory_regions() local
127 test_case->paddr, test_case->size); in ne_misc_dev_test_merge_phys_contig_memory_regions()
128 KUNIT_EXPECT_EQ(test, rc, test_case->expect_rc); in ne_misc_dev_test_merge_phys_contig_memory_regions()
129 KUNIT_EXPECT_EQ(test, phys_contig_mem_regions.num, test_case->expect_num); in ne_misc_dev_test_merge_phys_contig_memory_regions()
131 if (test_case->expect_last_paddr == INVALID_VALUE) in ne_misc_dev_test_merge_phys_contig_memory_regions()
136 test_case->expect_last_paddr); in ne_misc_dev_test_merge_phys_contig_memory_regions()
138 test_case->expect_last_size); in ne_misc_dev_test_merge_phys_contig_memory_regions()
/linux-6.15/tools/testing/selftests/kvm/
H A Dsystem_counter_offset_test.c19 struct test_case { struct
23 static struct test_case test_cases[] = { argument
36 static void setup_system_counter(struct kvm_vcpu *vcpu, struct test_case *test) in setup_system_counter()
42 static uint64_t guest_read_system_counter(struct test_case *test) in guest_read_system_counter()
47 static uint64_t host_read_guest_system_counter(struct test_case *test) in host_read_guest_system_counter()
66 struct test_case *test = &test_cases[i]; in guest_main()
96 struct test_case *test = &test_cases[i]; in enter_guest()
/linux-6.15/tools/testing/selftests/mm/
H A Dcow.c1164 run_with_base_page(test_case->fn, test_case->desc); in run_anon_test_case()
1165 run_with_base_page_swap(test_case->fn, test_case->desc); in run_anon_test_case()
1175 run_with_thp(test_case->fn, test_case->desc, size); in run_anon_test_case()
1176 run_with_thp_swap(test_case->fn, test_case->desc, size); in run_anon_test_case()
1189 run_with_hugetlb(test_case->fn, test_case->desc, in run_anon_test_case()
1431 struct test_case const *test_case = &anon_thp_test_cases[i]; in run_anon_thp_test_cases() local
1743 run_with_zeropage(test_case->fn, test_case->desc); in run_non_anon_test_case()
1744 run_with_memfd(test_case->fn, test_case->desc); in run_non_anon_test_case()
1745 run_with_tmpfile(test_case->fn, test_case->desc); in run_non_anon_test_case()
1747 run_with_huge_zeropage(test_case->fn, test_case->desc); in run_non_anon_test_case()
[all …]
H A Dgup_longterm.c337 struct test_case { struct
394 static const struct test_case test_cases[] = {
439 static void run_test_case(struct test_case const *test_case) in run_test_case() argument
443 run_with_memfd(test_case->fn, test_case->desc); in run_test_case()
444 run_with_tmpfile(test_case->fn, test_case->desc); in run_test_case()
445 run_with_local_tmpfile(test_case->fn, test_case->desc); in run_test_case()
447 run_with_memfd_hugetlb(test_case->fn, test_case->desc, in run_test_case()
H A Dmremap_test.c637 static void run_mremap_test_case(struct test test_case, int *failures, in run_mremap_test_case() argument
641 long long remap_time = remap_region(test_case.config, threshold_mb, in run_mremap_test_case()
645 if (test_case.expect_failure) in run_mremap_test_case()
647 test_case.name); in run_mremap_test_case()
649 ksft_test_result_fail("%s\n", test_case.name); in run_mremap_test_case()
658 test_case.config.region_size <= threshold_mb * _1MB) in run_mremap_test_case()
660 test_case.name, remap_time); in run_mremap_test_case()
662 ksft_test_result_pass("%s\n", test_case.name); in run_mremap_test_case()
/linux-6.15/tools/testing/selftests/kvm/x86/
H A Dkvm_clock_test.c19 struct test_case { struct
24 static struct test_case test_cases[] = { argument
77 static void setup_clock(struct kvm_vm *vm, struct test_case *test_case) in setup_clock() argument
83 data.clock = test_case->kvmclock_base; in setup_clock()
84 if (test_case->realtime_offset) { in setup_clock()
99 data.realtime += test_case->realtime_offset; in setup_clock()
/linux-6.15/samples/bpf/
H A Dtest_map_in_map.bpf.c109 u16 test_case, port, dst6[8]; in BPF_KSYSCALL() local
127 test_case = dst6[7]; in BPF_KSYSCALL()
138 if (test_case == 0) { in BPF_KSYSCALL()
140 } else if (test_case == 1) { in BPF_KSYSCALL()
142 } else if (test_case == 2) { in BPF_KSYSCALL()
159 if (test_case == 0 || test_case == 1) in BPF_KSYSCALL()
H A Dmap_perf_test.bpf.c188 u16 test_case; in BPF_KSYSCALL() local
205 test_case = test_params.tcase; in BPF_KSYSCALL()
206 if (test_case != 3) in BPF_KSYSCALL()
209 if (test_case == 0) { in BPF_KSYSCALL()
211 } else if (test_case == 1) { in BPF_KSYSCALL()
214 } else if (test_case == 2) { in BPF_KSYSCALL()
227 } else if (test_case == 3) { in BPF_KSYSCALL()
/linux-6.15/tools/testing/vsock/
H A Dutil.h27 struct test_case { struct
62 void run_tests(const struct test_case *test_cases,
64 void list_tests(const struct test_case *test_cases);
65 void skip_test(struct test_case *test_cases, size_t test_cases_len,
67 void pick_test(struct test_case *test_cases, size_t test_cases_len,
/linux-6.15/lib/
H A Dtest_kmod.c76 enum kmod_test_case test_case; member
142 switch (test_case) { in test_case_str()
196 switch (config->test_case) { in test_kmod_put_module()
216 switch (config->test_case) { in run_request()
424 config->test_case); in run_test_driver()
441 config->test_case); in run_test_fs_type()
473 config->test_case); in config_show()
515 config->test_case); in __trigger_config_run()
732 switch (test_case) { in trigger_config_run_type()
750 config->test_case = test_case; in trigger_config_run_type()
[all …]
/linux-6.15/tools/perf/tests/
H A Dbuiltin-test.c166 static const char *skip_reason(const struct test_suite *t, int test_case) in skip_reason() argument
171 return t->test_cases[test_case >= 0 ? test_case : 0].skip_reason; in skip_reason()
174 static const char *test_description(const struct test_suite *t, int test_case) in test_description() argument
176 if (t->test_cases && test_case >= 0) in test_description()
177 return t->test_cases[test_case].desc; in test_description()
182 static test_fnptr test_function(const struct test_suite *t, int test_case) in test_function() argument
184 if (test_case <= 0) in test_function()
187 return t->test_cases[test_case].run_case; in test_function()
190 static bool test_exclusive(const struct test_suite *t, int test_case) in test_exclusive() argument
192 if (test_case <= 0) in test_exclusive()
[all …]
H A Dtests.h34 struct test_case { struct
44 struct test_case *test_cases; argument
75 struct test_case tests__##_name[] = { \
85 struct test_case tests__##_name[] = { \
/linux-6.15/tools/perf/arch/x86/tests/
H A Darch-tests.c11 static struct test_case intel_pt_tests[] = {
28 static struct test_case hybrid_tests[] = {
/linux-6.15/tools/testing/selftests/kmod/
H A Dkmod.sh589 test_case $TEST_ID $TEST_COUNT
620 function test_case() function
650 test_case $1 $(get_test_count $1)
655 test_case $1 $2
658 test_case $1 1
/linux-6.15/net/mptcp/
H A Dcrypto_test.c6 struct test_case { struct
15 static struct test_case tests[] = { argument
/linux-6.15/tools/testing/selftests/sysctl/
H A Dsysctl.sh977 test_case $TEST_ID $TEST_COUNT $TEST_TARGET
1008 function test_case() function
1041 test_case $1 $(get_test_count $1) $(get_test_target $1)
1046 test_case $1 $2 $(get_test_target $1)
1049 test_case $1 1 $(get_test_target $1)

123