Home
last modified time | relevance | path

Searched refs:test (Results 1 - 25 of 1034) sorted by relevance

12345678910>>...42

/kernel/linux/linux-5.10/tools/perf/tests/
H A Dtests.h30 struct test { struct
32 int (*func)(struct test *test, int subtest);
44 int test__vmlinux_matches_kallsyms(struct test *test, int subtest);
45 int test__openat_syscall_event(struct test *test, int subtest);
46 int test__openat_syscall_event_on_all_cpus(struct test *test, int subtest);
47 int test__basic_mmap(struct test *tes
[all...]
/kernel/linux/linux-6.6/drivers/gpu/drm/tests/
H A Ddrm_cmdline_parser_test.c7 #include <kunit/test.h>
14 static void drm_test_cmdline_force_e_only(struct kunit *test) in drm_test_cmdline_force_e_only() argument
19 KUNIT_ASSERT_TRUE(test, drm_mode_parse_command_line_for_connector(cmdline, in drm_test_cmdline_force_e_only()
21 KUNIT_EXPECT_FALSE(test, mode.specified); in drm_test_cmdline_force_e_only()
22 KUNIT_EXPECT_FALSE(test, mode.refresh_specified); in drm_test_cmdline_force_e_only()
23 KUNIT_EXPECT_FALSE(test, mode.bpp_specified); in drm_test_cmdline_force_e_only()
25 KUNIT_EXPECT_FALSE(test, mode.rb); in drm_test_cmdline_force_e_only()
26 KUNIT_EXPECT_FALSE(test, mode.cvt); in drm_test_cmdline_force_e_only()
27 KUNIT_EXPECT_FALSE(test, mode.interlace); in drm_test_cmdline_force_e_only()
28 KUNIT_EXPECT_FALSE(test, mod in drm_test_cmdline_force_e_only()
32 drm_test_cmdline_force_D_only_not_digital(struct kunit *test) drm_test_cmdline_force_D_only_not_digital() argument
54 drm_test_cmdline_force_D_only_hdmi(struct kunit *test) drm_test_cmdline_force_D_only_hdmi() argument
76 drm_test_cmdline_force_D_only_dvi(struct kunit *test) drm_test_cmdline_force_D_only_dvi() argument
94 drm_test_cmdline_force_d_only(struct kunit *test) drm_test_cmdline_force_d_only() argument
112 drm_test_cmdline_res(struct kunit *test) drm_test_cmdline_res() argument
134 drm_test_cmdline_res_vesa(struct kunit *test) drm_test_cmdline_res_vesa() argument
156 drm_test_cmdline_res_vesa_rblank(struct kunit *test) drm_test_cmdline_res_vesa_rblank() argument
178 drm_test_cmdline_res_rblank(struct kunit *test) drm_test_cmdline_res_rblank() argument
200 drm_test_cmdline_res_bpp(struct kunit *test) drm_test_cmdline_res_bpp() argument
223 drm_test_cmdline_res_refresh(struct kunit *test) drm_test_cmdline_res_refresh() argument
246 drm_test_cmdline_res_bpp_refresh(struct kunit *test) drm_test_cmdline_res_bpp_refresh() argument
270 drm_test_cmdline_res_bpp_refresh_interlaced(struct kunit *test) drm_test_cmdline_res_bpp_refresh_interlaced() argument
294 drm_test_cmdline_res_bpp_refresh_margins(struct kunit *test) drm_test_cmdline_res_bpp_refresh_margins() argument
318 drm_test_cmdline_res_bpp_refresh_force_off(struct kunit *test) drm_test_cmdline_res_bpp_refresh_force_off() argument
342 drm_test_cmdline_res_bpp_refresh_force_on(struct kunit *test) drm_test_cmdline_res_bpp_refresh_force_on() argument
366 drm_test_cmdline_res_bpp_refresh_force_on_analog(struct kunit *test) drm_test_cmdline_res_bpp_refresh_force_on_analog() argument
390 drm_test_cmdline_res_bpp_refresh_force_on_digital(struct kunit *test) drm_test_cmdline_res_bpp_refresh_force_on_digital() argument
417 drm_test_cmdline_res_bpp_refresh_interlaced_margins_force_on(struct kunit *test) drm_test_cmdline_res_bpp_refresh_interlaced_margins_force_on() argument
441 drm_test_cmdline_res_margins_force_on(struct kunit *test) drm_test_cmdline_res_margins_force_on() argument
463 drm_test_cmdline_res_vesa_margins(struct kunit *test) drm_test_cmdline_res_vesa_margins() argument
485 drm_test_cmdline_name(struct kunit *test) drm_test_cmdline_name() argument
497 drm_test_cmdline_name_bpp(struct kunit *test) drm_test_cmdline_name_bpp() argument
512 drm_test_cmdline_name_option(struct kunit *test) drm_test_cmdline_name_option() argument
524 drm_test_cmdline_name_bpp_option(struct kunit *test) drm_test_cmdline_name_bpp_option() argument
538 drm_test_cmdline_rotate_0(struct kunit *test) drm_test_cmdline_rotate_0() argument
561 drm_test_cmdline_rotate_90(struct kunit *test) drm_test_cmdline_rotate_90() argument
584 drm_test_cmdline_rotate_180(struct kunit *test) drm_test_cmdline_rotate_180() argument
607 drm_test_cmdline_rotate_270(struct kunit *test) drm_test_cmdline_rotate_270() argument
630 drm_test_cmdline_hmirror(struct kunit *test) drm_test_cmdline_hmirror() argument
653 drm_test_cmdline_vmirror(struct kunit *test) drm_test_cmdline_vmirror() argument
676 drm_test_cmdline_margin_options(struct kunit *test) drm_test_cmdline_margin_options() argument
703 drm_test_cmdline_multiple_options(struct kunit *test) drm_test_cmdline_multiple_options() argument
726 drm_test_cmdline_bpp_extra_and_option(struct kunit *test) drm_test_cmdline_bpp_extra_and_option() argument
750 drm_test_cmdline_extra_and_option(struct kunit *test) drm_test_cmdline_extra_and_option() argument
772 drm_test_cmdline_freestanding_options(struct kunit *test) drm_test_cmdline_freestanding_options() argument
795 drm_test_cmdline_freestanding_force_e_and_options(struct kunit *test) drm_test_cmdline_freestanding_force_e_and_options() argument
818 drm_test_cmdline_panel_orientation(struct kunit *test) drm_test_cmdline_panel_orientation() argument
843 drm_test_cmdline_invalid(struct kunit *test) drm_test_cmdline_invalid() argument
955 drm_test_cmdline_tv_options(struct kunit *test) drm_test_cmdline_tv_options() argument
[all...]
H A Ddrm_format_test.c8 #include <kunit/test.h>
12 static void drm_test_format_block_width_invalid(struct kunit *test) in drm_test_format_block_width_invalid() argument
16 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 0), 0); in drm_test_format_block_width_invalid()
17 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, -1), 0); in drm_test_format_block_width_invalid()
18 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 1), 0); in drm_test_format_block_width_invalid()
21 static void drm_test_format_block_width_one_plane(struct kunit *test) in drm_test_format_block_width_one_plane() argument
25 KUNIT_ASSERT_NOT_NULL(test, info); in drm_test_format_block_width_one_plane()
27 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 0), 1); in drm_test_format_block_width_one_plane()
28 KUNIT_EXPECT_EQ(test, drm_format_info_block_width(info, 1), 0); in drm_test_format_block_width_one_plane()
29 KUNIT_EXPECT_EQ(test, drm_format_info_block_widt in drm_test_format_block_width_one_plane()
32 drm_test_format_block_width_two_plane(struct kunit *test) drm_test_format_block_width_two_plane() argument
44 drm_test_format_block_width_three_plane(struct kunit *test) drm_test_format_block_width_three_plane() argument
57 drm_test_format_block_width_tiled(struct kunit *test) drm_test_format_block_width_tiled() argument
68 drm_test_format_block_height_invalid(struct kunit *test) drm_test_format_block_height_invalid() argument
77 drm_test_format_block_height_one_plane(struct kunit *test) drm_test_format_block_height_one_plane() argument
88 drm_test_format_block_height_two_plane(struct kunit *test) drm_test_format_block_height_two_plane() argument
100 drm_test_format_block_height_three_plane(struct kunit *test) drm_test_format_block_height_three_plane() argument
113 drm_test_format_block_height_tiled(struct kunit *test) drm_test_format_block_height_tiled() argument
124 drm_test_format_min_pitch_invalid(struct kunit *test) drm_test_format_min_pitch_invalid() argument
133 drm_test_format_min_pitch_one_plane_8bpp(struct kunit *test) drm_test_format_min_pitch_one_plane_8bpp() argument
156 drm_test_format_min_pitch_one_plane_16bpp(struct kunit *test) drm_test_format_min_pitch_one_plane_16bpp() argument
179 drm_test_format_min_pitch_one_plane_24bpp(struct kunit *test) drm_test_format_min_pitch_one_plane_24bpp() argument
202 drm_test_format_min_pitch_one_plane_32bpp(struct kunit *test) drm_test_format_min_pitch_one_plane_32bpp() argument
225 drm_test_format_min_pitch_two_plane(struct kunit *test) drm_test_format_min_pitch_two_plane() argument
260 drm_test_format_min_pitch_three_plane_8bpp(struct kunit *test) drm_test_format_min_pitch_three_plane_8bpp() argument
307 drm_test_format_min_pitch_tiled(struct kunit *test) drm_test_format_min_pitch_tiled() argument
[all...]
/kernel/linux/linux-6.6/lib/kunit/
H A Dkunit-test.c3 * KUnit test for core test infrastructure.
8 #include <kunit/test.h>
9 #include <kunit/test-bug.h>
20 struct kunit *test = data; in kunit_test_successful_try() local
21 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_successful_try()
28 struct kunit *test = data; in kunit_test_no_catch() local
30 KUNIT_FAIL(test, "Catch should not be called\n"); in kunit_test_no_catch()
33 static void kunit_test_try_catch_successful_try_no_catch(struct kunit *test) in kunit_test_try_catch_successful_try_no_catch() argument
35 struct kunit_try_catch_test_context *ctx = test in kunit_test_try_catch_successful_try_no_catch()
49 struct kunit *test = data; kunit_test_unsuccessful_try() local
59 struct kunit *test = data; kunit_test_catch() local
65 kunit_test_try_catch_unsuccessful_try_does_catch(struct kunit *test) kunit_test_try_catch_unsuccessful_try_does_catch() argument
79 kunit_try_catch_test_init(struct kunit *test) kunit_try_catch_test_init() argument
112 struct kunit test; global() member
134 kunit_resource_test_init_resources(struct kunit *test) kunit_resource_test_init_resources() argument
143 kunit_resource_test_alloc_resource(struct kunit *test) kunit_resource_test_alloc_resource() argument
165 kunit_resource_instance_match(struct kunit *test, struct kunit_resource *res, void *match_data) kunit_resource_instance_match() argument
180 kunit_resource_test_destroy_resource(struct kunit *test) kunit_resource_test_destroy_resource() argument
201 kunit_resource_test_remove_resource(struct kunit *test) kunit_resource_test_remove_resource() argument
235 kunit_resource_test_cleanup_resources(struct kunit *test) kunit_resource_test_cleanup_resources() argument
322 kunit_resource_test_proper_free_ordering(struct kunit *test) kunit_resource_test_proper_free_ordering() argument
355 kunit_resource_test_static(struct kunit *test) kunit_resource_test_static() argument
370 kunit_resource_test_named(struct kunit *test) kunit_resource_test_named() argument
412 kunit_resource_test_action(struct kunit *test) kunit_resource_test_action() argument
431 kunit_resource_test_remove_action(struct kunit *test) kunit_resource_test_remove_action() argument
442 kunit_resource_test_release_action(struct kunit *test) kunit_resource_test_release_action() argument
470 kunit_resource_test_action_ordering(struct kunit *test) kunit_resource_test_action_ordering() argument
488 kunit_resource_test_init(struct kunit *test) kunit_resource_test_init() argument
502 kunit_resource_test_exit(struct kunit *test) kunit_resource_test_exit() argument
533 kunit_log_test(struct kunit *test) kunit_log_test() argument
559 kunit_log_newline_test(struct kunit *test) kunit_log_newline_test() argument
582 kunit_status_set_failure_test(struct kunit *test) kunit_status_set_failure_test() argument
593 kunit_status_mark_skipped_test(struct kunit *test) kunit_status_mark_skipped_test() argument
622 kunit_current_test(struct kunit *test) kunit_current_test() argument
631 kunit_current_fail_test(struct kunit *test) kunit_current_fail_test() argument
[all...]
H A Dkunit-example-test.c3 * Example KUnit test to show how to use KUnit.
9 #include <kunit/test.h>
13 * This is the most fundamental element of KUnit, the test case. A test case
15 * any expectations or assertions are not met, the test fails; otherwise, the
16 * test passes.
18 * In KUnit, a test case is just a function with the signature
20 * information about the current test.
22 static void example_simple_test(struct kunit *test) in example_simple_test() argument
26 * to test in example_simple_test()
37 example_test_init(struct kunit *test) example_test_init() argument
48 example_test_exit(struct kunit *test) example_test_exit() argument
78 example_skip_test(struct kunit *test) example_skip_test() argument
93 example_mark_skipped_test(struct kunit *test) example_mark_skipped_test() argument
108 example_all_expect_macros_test(struct kunit *test) example_all_expect_macros_test() argument
174 example_static_stub_test(struct kunit *test) example_static_stub_test() argument
208 example_params_test(struct kunit *test) example_params_test() argument
226 example_slow_test(struct kunit *test) example_slow_test() argument
[all...]
H A Dexecutor_test.c3 * KUnit test for the KUnit executor.
9 #include <kunit/test.h>
12 static void free_suite_set_at_end(struct kunit *test, const void *to_free);
13 static struct kunit_suite *alloc_fake_suite(struct kunit *test,
17 static void dummy_test(struct kunit *test) {} in dummy_test() argument
26 static void parse_filter_test(struct kunit *test) in parse_filter_test() argument
31 KUNIT_EXPECT_STREQ(test, filter.suite_glob, "suite"); in parse_filter_test()
32 KUNIT_EXPECT_FALSE(test, filter.test_glob); in parse_filter_test()
36 kunit_parse_glob_filter(&filter, "suite.test"); in parse_filter_test()
37 KUNIT_EXPECT_STREQ(test, filte in parse_filter_test()
43 filter_suites_test(struct kunit *test) filter_suites_test() argument
69 filter_suites_test_glob_test(struct kunit *test) filter_suites_test_glob_test() argument
98 filter_suites_to_empty_test(struct kunit *test) filter_suites_to_empty_test() argument
118 parse_filter_attr_test(struct kunit *test) parse_filter_attr_test() argument
150 filter_attr_test(struct kunit *test) filter_attr_test() argument
188 filter_attr_empty_test(struct kunit *test) filter_attr_empty_test() argument
209 filter_attr_skip_test(struct kunit *test) filter_attr_skip_test() argument
268 free_suite_set_at_end(struct kunit *test, const void *to_free) free_suite_set_at_end() argument
281 alloc_fake_suite(struct kunit *test, const char *suite_name, struct kunit_case *test_cases) alloc_fake_suite() argument
[all...]
/kernel/linux/linux-6.6/drivers/base/test/
H A Dproperty-entry-test.c6 #include <kunit/test.h>
10 static void pe_test_uints(struct kunit *test) in pe_test_uints() argument
28 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, node); in pe_test_uints()
31 KUNIT_EXPECT_EQ(test, error, 1); in pe_test_uints()
34 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints()
35 KUNIT_EXPECT_EQ(test, val_u8, 8); in pe_test_uints()
38 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints()
39 KUNIT_EXPECT_EQ(test, array_u8[0], 8); in pe_test_uints()
42 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints()
45 KUNIT_EXPECT_NE(test, erro in pe_test_uints()
117 pe_test_uint_arrays(struct kunit *test) pe_test_uint_arrays() argument
252 pe_test_strings(struct kunit *test) pe_test_strings() argument
324 pe_test_bool(struct kunit *test) pe_test_bool() argument
343 pe_test_move_inline_u8(struct kunit *test) pe_test_move_inline_u8() argument
373 pe_test_move_inline_str(struct kunit *test) pe_test_move_inline_str() argument
406 pe_test_reference(struct kunit *test) pe_test_reference() argument
[all...]
/kernel/linux/linux-5.10/include/kunit/
H A Dtest.h3 * Base unit test (KUnit) API.
26 * struct kunit_resource - represents a *test managed resource*
32 * Represents a *test managed resource*, a resource which will automatically be
33 * cleaned up at the end of a test case.
66 * void *kunit_kmalloc(struct kunit *test, size_t size, gfp_t gfp)
73 * return kunit_alloc_resource(test, kunit_kmalloc_init,
80 * unique within the test instance.
94 /* Size of log associated with test. */
106 * struct kunit_case - represents an individual test case.
108 * @run_case: the function representing the actual test cas
228 kunit_set_failure(struct kunit *test) kunit_set_failure() argument
425 kunit_alloc_resource(struct kunit *test, kunit_resource_init_t init, kunit_resource_free_t free, gfp_t internal_gfp, void *context) kunit_alloc_resource() argument
456 kunit_resource_instance_match(struct kunit *test, struct kunit_resource *res, void *match_data) kunit_resource_instance_match() argument
469 kunit_resource_name_match(struct kunit *test, struct kunit_resource *res, void *match_name) kunit_resource_name_match() argument
483 kunit_find_resource(struct kunit *test, kunit_resource_match_t match, void *match_data) kunit_find_resource() argument
510 kunit_find_named_resource(struct kunit *test, const char *name) kunit_find_named_resource() argument
530 kunit_destroy_named_resource(struct kunit *test, const char *name) kunit_destroy_named_resource() argument
576 kunit_kzalloc(struct kunit *test, size_t size, gfp_t gfp) kunit_kzalloc() argument
[all...]
/kernel/linux/linux-5.10/lib/kunit/
H A Dkunit-test.c3 * KUnit test for core test infrastructure.
8 #include <kunit/test.h>
19 struct kunit *test = data; in kunit_test_successful_try() local
20 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_successful_try()
27 struct kunit *test = data; in kunit_test_no_catch() local
29 KUNIT_FAIL(test, "Catch should not be called\n"); in kunit_test_no_catch()
32 static void kunit_test_try_catch_successful_try_no_catch(struct kunit *test) in kunit_test_try_catch_successful_try_no_catch() argument
34 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_try_catch_successful_try_no_catch()
38 test, in kunit_test_try_catch_successful_try_no_catch()
48 struct kunit *test = data; kunit_test_unsuccessful_try() local
58 struct kunit *test = data; kunit_test_catch() local
64 kunit_test_try_catch_unsuccessful_try_does_catch(struct kunit *test) kunit_test_try_catch_unsuccessful_try_does_catch() argument
78 kunit_try_catch_test_init(struct kunit *test) kunit_try_catch_test_init() argument
111 struct kunit test; global() member
133 kunit_resource_test_init_resources(struct kunit *test) kunit_resource_test_init_resources() argument
142 kunit_resource_test_alloc_resource(struct kunit *test) kunit_resource_test_alloc_resource() argument
172 kunit_resource_test_destroy_resource(struct kunit *test) kunit_resource_test_destroy_resource() argument
193 kunit_resource_test_cleanup_resources(struct kunit *test) kunit_resource_test_cleanup_resources() argument
280 kunit_resource_test_proper_free_ordering(struct kunit *test) kunit_resource_test_proper_free_ordering() argument
313 kunit_resource_test_static(struct kunit *test) kunit_resource_test_static() argument
328 kunit_resource_test_named(struct kunit *test) kunit_resource_test_named() argument
364 kunit_resource_test_init(struct kunit *test) kunit_resource_test_init() argument
378 kunit_resource_test_exit(struct kunit *test) kunit_resource_test_exit() argument
416 kunit_log_test(struct kunit *test) kunit_log_test() argument
[all...]
/kernel/linux/linux-5.10/drivers/base/test/
H A Dproperty-entry-test.c6 #include <kunit/test.h>
10 static void pe_test_uints(struct kunit *test) in pe_test_uints() argument
28 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, node); in pe_test_uints()
31 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints()
32 KUNIT_EXPECT_EQ(test, (int)val_u8, 8); in pe_test_uints()
35 KUNIT_EXPECT_EQ(test, error, 0); in pe_test_uints()
36 KUNIT_EXPECT_EQ(test, (int)array_u8[0], 8); in pe_test_uints()
39 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints()
42 KUNIT_EXPECT_NE(test, error, 0); in pe_test_uints()
45 KUNIT_EXPECT_NE(test, erro in pe_test_uints()
101 pe_test_uint_arrays(struct kunit *test) pe_test_uint_arrays() argument
216 pe_test_strings(struct kunit *test) pe_test_strings() argument
282 pe_test_bool(struct kunit *test) pe_test_bool() argument
301 pe_test_move_inline_u8(struct kunit *test) pe_test_move_inline_u8() argument
331 pe_test_move_inline_str(struct kunit *test) pe_test_move_inline_str() argument
364 pe_test_reference(struct kunit *test) pe_test_reference() argument
[all...]
/kernel/linux/linux-6.6/drivers/thunderbolt/
H A Dtest.c9 #include <kunit/test.h>
31 static void kunit_ida_init(struct kunit *test, struct ida *ida) in kunit_ida_init() argument
33 kunit_alloc_resource(test, __ida_init, __ida_destroy, GFP_KERNEL, ida); in kunit_ida_init()
36 static struct tb_switch *alloc_switch(struct kunit *test, u64 route, in alloc_switch() argument
43 sw = kunit_kzalloc(test, sizeof(*sw), GFP_KERNEL); in alloc_switch()
55 sw->ports = kunit_kzalloc(test, size, GFP_KERNEL); in alloc_switch()
64 kunit_ida_init(test, &sw->ports[i].in_hopids); in alloc_switch()
65 kunit_ida_init(test, &sw->ports[i].out_hopids); in alloc_switch()
72 static struct tb_switch *alloc_host(struct kunit *test) in alloc_host() argument
76 sw = alloc_switch(test, in alloc_host()
154 alloc_host_usb4(struct kunit *test) alloc_host_usb4() argument
173 alloc_host_br(struct kunit *test) alloc_host_br() argument
190 alloc_dev_default(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_default() argument
340 alloc_dev_with_dpin(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_with_dpin() argument
361 alloc_dev_without_dp(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_without_dp() argument
402 alloc_dev_usb4(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_usb4() argument
423 tb_test_path_basic(struct kunit *test) tb_test_path_basic() argument
440 tb_test_path_not_connected_walk(struct kunit *test) tb_test_path_not_connected_walk() argument
479 tb_test_path_single_hop_walk(struct kunit *test) tb_test_path_single_hop_walk() argument
533 tb_test_path_daisy_chain_walk(struct kunit *test) tb_test_path_daisy_chain_walk() argument
592 tb_test_path_simple_tree_walk(struct kunit *test) tb_test_path_simple_tree_walk() argument
655 tb_test_path_complex_tree_walk(struct kunit *test) tb_test_path_complex_tree_walk() argument
739 tb_test_path_max_length_walk(struct kunit *test) tb_test_path_max_length_walk() argument
842 tb_test_path_not_connected(struct kunit *test) tb_test_path_not_connected() argument
870 tb_test_path_not_bonded_lane0(struct kunit *test) tb_test_path_not_bonded_lane0() argument
928 tb_test_path_not_bonded_lane1(struct kunit *test) tb_test_path_not_bonded_lane1() argument
990 tb_test_path_not_bonded_lane1_chain(struct kunit *test) tb_test_path_not_bonded_lane1_chain() argument
1070 tb_test_path_not_bonded_lane1_chain_reverse(struct kunit *test) tb_test_path_not_bonded_lane1_chain_reverse() argument
1150 tb_test_path_mixed_chain(struct kunit *test) tb_test_path_mixed_chain() argument
1242 tb_test_path_mixed_chain_reverse(struct kunit *test) tb_test_path_mixed_chain_reverse() argument
1334 tb_test_tunnel_pcie(struct kunit *test) tb_test_tunnel_pcie() argument
1389 tb_test_tunnel_dp(struct kunit *test) tb_test_tunnel_dp() argument
1427 tb_test_tunnel_dp_chain(struct kunit *test) tb_test_tunnel_dp_chain() argument
1473 tb_test_tunnel_dp_tree(struct kunit *test) tb_test_tunnel_dp_tree() argument
1523 tb_test_tunnel_dp_max_length(struct kunit *test) tb_test_tunnel_dp_max_length() argument
1603 tb_test_tunnel_3dp(struct kunit *test) tb_test_tunnel_3dp() argument
1668 tb_test_tunnel_usb3(struct kunit *test) tb_test_tunnel_usb3() argument
1723 tb_test_tunnel_port_on_path(struct kunit *test) tb_test_tunnel_port_on_path() argument
1789 tb_test_tunnel_dma(struct kunit *test) tb_test_tunnel_dma() argument
1832 tb_test_tunnel_dma_rx(struct kunit *test) tb_test_tunnel_dma_rx() argument
1869 tb_test_tunnel_dma_tx(struct kunit *test) tb_test_tunnel_dma_tx() argument
1906 tb_test_tunnel_dma_chain(struct kunit *test) tb_test_tunnel_dma_chain() argument
1972 tb_test_tunnel_dma_match(struct kunit *test) tb_test_tunnel_dma_match() argument
2023 tb_test_credit_alloc_legacy_not_bonded(struct kunit *test) tb_test_credit_alloc_legacy_not_bonded() argument
2056 tb_test_credit_alloc_legacy_bonded(struct kunit *test) tb_test_credit_alloc_legacy_bonded() argument
2089 tb_test_credit_alloc_pcie(struct kunit *test) tb_test_credit_alloc_pcie() argument
2122 tb_test_credit_alloc_without_dp(struct kunit *test) tb_test_credit_alloc_without_dp() argument
2172 tb_test_credit_alloc_dp(struct kunit *test) tb_test_credit_alloc_dp() argument
2216 tb_test_credit_alloc_usb3(struct kunit *test) tb_test_credit_alloc_usb3() argument
2249 tb_test_credit_alloc_dma(struct kunit *test) tb_test_credit_alloc_dma() argument
2285 tb_test_credit_alloc_dma_multiple(struct kunit *test) tb_test_credit_alloc_dma_multiple() argument
2382 TB_TEST_PCIE_TUNNEL(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_PCIE_TUNNEL() argument
2412 TB_TEST_DP_TUNNEL1(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_DP_TUNNEL1() argument
2449 TB_TEST_DP_TUNNEL2(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_DP_TUNNEL2() argument
2486 TB_TEST_USB3_TUNNEL(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_USB3_TUNNEL() argument
2516 TB_TEST_DMA_TUNNEL1(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_DMA_TUNNEL1() argument
2546 TB_TEST_DMA_TUNNEL2(struct kunit *test, struct tb_switch *host, struct tb_switch *dev) TB_TEST_DMA_TUNNEL2() argument
2576 tb_test_credit_alloc_all(struct kunit *test) tb_test_credit_alloc_all() argument
2666 tb_test_property_parse(struct kunit *test) tb_test_property_parse() argument
2726 tb_test_property_format(struct kunit *test) tb_test_property_format() argument
2753 compare_dirs(struct kunit *test, struct tb_property_dir *d1, struct tb_property_dir *d2) compare_dirs() argument
2823 tb_test_property_copy(struct kunit *test) tb_test_property_copy() argument
[all...]
/kernel/linux/linux-6.6/mm/kasan/
H A Dkasan_test.c10 #include <kunit/test.h>
88 static void kasan_test_exit(struct kunit *test) in kasan_test_exit() argument
90 KUNIT_EXPECT_FALSE(test, READ_ONCE(test_status.report_found)); in kasan_test_exit()
95 * KASAN report; causes a test failure otherwise. This relies on a KUnit
100 * checking is auto-disabled. When this happens, this test handler reenables
114 #define KUNIT_EXPECT_KASAN_FAIL(test, expression) do { \
118 KUNIT_EXPECT_FALSE(test, READ_ONCE(test_status.report_found)); \
125 KUNIT_FAIL(test, KUNIT_SUBTEST_INDENT "KASAN failure " \
140 #define KASAN_TEST_NEEDS_CONFIG_ON(test, config) do { \
142 kunit_skip((test), "Tes
159 kmalloc_oob_right(struct kunit *test) kmalloc_oob_right() argument
188 kmalloc_oob_left(struct kunit *test) kmalloc_oob_left() argument
201 kmalloc_node_oob_right(struct kunit *test) kmalloc_node_oob_right() argument
220 kmalloc_pagealloc_oob_right(struct kunit *test) kmalloc_pagealloc_oob_right() argument
236 kmalloc_pagealloc_uaf(struct kunit *test) kmalloc_pagealloc_uaf() argument
250 kmalloc_pagealloc_invalid_free(struct kunit *test) kmalloc_pagealloc_invalid_free() argument
263 pagealloc_oob_right(struct kunit *test) pagealloc_oob_right() argument
285 pagealloc_uaf(struct kunit *test) pagealloc_uaf() argument
299 kmalloc_large_oob_right(struct kunit *test) kmalloc_large_oob_right() argument
316 krealloc_more_oob_helper(struct kunit *test, size_t size1, size_t size2) krealloc_more_oob_helper() argument
351 krealloc_less_oob_helper(struct kunit *test, size_t size1, size_t size2) krealloc_less_oob_helper() argument
395 krealloc_more_oob(struct kunit *test) krealloc_more_oob() argument
400 krealloc_less_oob(struct kunit *test) krealloc_less_oob() argument
405 krealloc_pagealloc_more_oob(struct kunit *test) krealloc_pagealloc_more_oob() argument
414 krealloc_pagealloc_less_oob(struct kunit *test) krealloc_pagealloc_less_oob() argument
427 krealloc_uaf(struct kunit *test) krealloc_uaf() argument
442 kmalloc_oob_16(struct kunit *test) kmalloc_oob_16() argument
467 kmalloc_uaf_16(struct kunit *test) kmalloc_uaf_16() argument
492 kmalloc_oob_memset_2(struct kunit *test) kmalloc_oob_memset_2() argument
507 kmalloc_oob_memset_4(struct kunit *test) kmalloc_oob_memset_4() argument
522 kmalloc_oob_memset_8(struct kunit *test) kmalloc_oob_memset_8() argument
537 kmalloc_oob_memset_16(struct kunit *test) kmalloc_oob_memset_16() argument
552 kmalloc_oob_in_memset(struct kunit *test) kmalloc_oob_in_memset() argument
569 kmalloc_memmove_negative_size(struct kunit *test) kmalloc_memmove_negative_size() argument
595 kmalloc_memmove_invalid_size(struct kunit *test) kmalloc_memmove_invalid_size() argument
614 kmalloc_uaf(struct kunit *test) kmalloc_uaf() argument
626 kmalloc_uaf_memset(struct kunit *test) kmalloc_uaf_memset() argument
646 kmalloc_uaf2(struct kunit *test) kmalloc_uaf2() argument
680 kmalloc_uaf3(struct kunit *test) kmalloc_uaf3() argument
699 kfree_via_page(struct kunit *test) kfree_via_page() argument
714 kfree_via_phys(struct kunit *test) kfree_via_phys() argument
727 kmem_cache_oob(struct kunit *test) kmem_cache_oob() argument
749 kmem_cache_accounted(struct kunit *test) kmem_cache_accounted() argument
776 kmem_cache_bulk(struct kunit *test) kmem_cache_bulk() argument
803 kasan_global_oob_right(struct kunit *test) kasan_global_oob_right() argument
826 kasan_global_oob_left(struct kunit *test) kasan_global_oob_left() argument
841 ksize_unpoisons_memory(struct kunit *test) ksize_unpoisons_memory() argument
872 ksize_uaf(struct kunit *test) ksize_uaf() argument
887 kasan_stack_oob(struct kunit *test) kasan_stack_oob() argument
899 kasan_alloca_oob_left(struct kunit *test) kasan_alloca_oob_left() argument
914 kasan_alloca_oob_right(struct kunit *test) kasan_alloca_oob_right() argument
929 kmem_cache_double_free(struct kunit *test) kmem_cache_double_free() argument
950 kmem_cache_invalid_free(struct kunit *test) kmem_cache_invalid_free() argument
981 kmem_cache_double_destroy(struct kunit *test) kmem_cache_double_destroy() argument
992 kasan_memchr(struct kunit *test) kasan_memchr() argument
1017 kasan_memcmp(struct kunit *test) kasan_memcmp() argument
1043 kasan_strings(struct kunit *test) kasan_strings() argument
1079 kasan_bitops_modify(struct kunit *test, int nr, void *addr) kasan_bitops_modify() argument
1091 kasan_bitops_test_and_modify(struct kunit *test, int nr, void *addr) kasan_bitops_test_and_modify() argument
1108 kasan_bitops_generic(struct kunit *test) kasan_bitops_generic() argument
1137 kasan_bitops_tags(struct kunit *test) kasan_bitops_tags() argument
1155 kmalloc_double_kzfree(struct kunit *test) kmalloc_double_kzfree() argument
1189 rcu_uaf(struct kunit *test) rcu_uaf() argument
1209 workqueue_uaf(struct kunit *test) workqueue_uaf() argument
1228 vmalloc_helpers_tags(struct kunit *test) vmalloc_helpers_tags() argument
1263 vmalloc_oob(struct kunit *test) vmalloc_oob() argument
1311 vmap_tags(struct kunit *test) vmap_tags() argument
1354 vm_map_ram_tags(struct kunit *test) vm_map_ram_tags() argument
1384 vmalloc_percpu(struct kunit *test) vmalloc_percpu() argument
1415 match_all_not_assigned(struct kunit *test) match_all_not_assigned() argument
1456 match_all_ptr_tag(struct kunit *test) match_all_ptr_tag() argument
1482 match_all_mem_tag(struct kunit *test) match_all_mem_tag() argument
[all...]
/kernel/linux/linux-5.10/lib/
H A Dtest_kasan.c24 #include <kunit/test.h>
31 * We assign some test results to these globals to make sure the tests
42 static int kasan_test_init(struct kunit *test) in kasan_test_init() argument
53 static void kasan_test_exit(struct kunit *test) in kasan_test_exit() argument
59 * KUNIT_EXPECT_KASAN_FAIL() - Causes a test failure when the expression does
64 #define KUNIT_EXPECT_KASAN_FAIL(test, condition) do { \
67 kunit_add_named_resource(test, \
73 KUNIT_EXPECT_EQ(test, \
78 static void kmalloc_oob_right(struct kunit *test) in kmalloc_oob_right() argument
84 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, pt in kmalloc_oob_right()
90 kmalloc_oob_left(struct kunit *test) kmalloc_oob_left() argument
102 kmalloc_node_oob_right(struct kunit *test) kmalloc_node_oob_right() argument
114 kmalloc_pagealloc_oob_right(struct kunit *test) kmalloc_pagealloc_oob_right() argument
134 kmalloc_pagealloc_uaf(struct kunit *test) kmalloc_pagealloc_uaf() argument
151 kmalloc_pagealloc_invalid_free(struct kunit *test) kmalloc_pagealloc_invalid_free() argument
167 kmalloc_large_oob_right(struct kunit *test) kmalloc_large_oob_right() argument
181 kmalloc_oob_krealloc_more(struct kunit *test) kmalloc_oob_krealloc_more() argument
197 kmalloc_oob_krealloc_less(struct kunit *test) kmalloc_oob_krealloc_less() argument
213 kmalloc_oob_16(struct kunit *test) kmalloc_oob_16() argument
236 kmalloc_uaf_16(struct kunit *test) kmalloc_uaf_16() argument
253 kmalloc_oob_memset_2(struct kunit *test) kmalloc_oob_memset_2() argument
265 kmalloc_oob_memset_4(struct kunit *test) kmalloc_oob_memset_4() argument
278 kmalloc_oob_memset_8(struct kunit *test) kmalloc_oob_memset_8() argument
290 kmalloc_oob_memset_16(struct kunit *test) kmalloc_oob_memset_16() argument
302 kmalloc_oob_in_memset(struct kunit *test) kmalloc_oob_in_memset() argument
314 kmalloc_memmove_invalid_size(struct kunit *test) kmalloc_memmove_invalid_size() argument
330 kmalloc_uaf(struct kunit *test) kmalloc_uaf() argument
342 kmalloc_uaf_memset(struct kunit *test) kmalloc_uaf_memset() argument
354 kmalloc_uaf2(struct kunit *test) kmalloc_uaf2() argument
373 kfree_via_page(struct kunit *test) kfree_via_page() argument
388 kfree_via_phys(struct kunit *test) kfree_via_phys() argument
401 kmem_cache_oob(struct kunit *test) kmem_cache_oob() argument
421 memcg_accounted_kmem_cache(struct kunit *test) memcg_accounted_kmem_cache() argument
450 kasan_global_oob(struct kunit *test) kasan_global_oob() argument
476 ksize_unpoisons_memory(struct kunit *test) ksize_unpoisons_memory() argument
491 kasan_stack_oob(struct kunit *test) kasan_stack_oob() argument
506 kasan_alloca_oob_left(struct kunit *test) kasan_alloca_oob_left() argument
528 kasan_alloca_oob_right(struct kunit *test) kasan_alloca_oob_right() argument
550 kmem_cache_double_free(struct kunit *test) kmem_cache_double_free() argument
571 kmem_cache_invalid_free(struct kunit *test) kmem_cache_invalid_free() argument
600 kasan_memchr(struct kunit *test) kasan_memchr() argument
624 kasan_memcmp(struct kunit *test) kasan_memcmp() argument
649 kasan_strings(struct kunit *test) kasan_strings() argument
686 kasan_bitops_modify(struct kunit *test, int nr, void *addr) kasan_bitops_modify() argument
698 kasan_bitops_test_and_modify(struct kunit *test, int nr, void *addr) kasan_bitops_test_and_modify() argument
715 kasan_bitops_generic(struct kunit *test) kasan_bitops_generic() argument
747 kasan_bitops_tags(struct kunit *test) kasan_bitops_tags() argument
768 kmalloc_double_kzfree(struct kunit *test) kmalloc_double_kzfree() argument
780 vmalloc_oob(struct kunit *test) vmalloc_oob() argument
[all...]
H A Dlist-test.c3 * KUnit test for the Kernel Linked-list structures.
8 #include <kunit/test.h>
17 static void list_test_list_init(struct kunit *test) in list_test_list_init() argument
36 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list1)); in list_test_list_init()
37 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list2)); in list_test_list_init()
38 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list3)); in list_test_list_init()
39 KUNIT_EXPECT_TRUE(test, list_empty_careful(list4)); in list_test_list_init()
40 KUNIT_EXPECT_TRUE(test, list_empty_careful(list5)); in list_test_list_init()
46 static void list_test_list_add(struct kunit *test) in list_test_list_add() argument
55 KUNIT_EXPECT_PTR_EQ(test, lis in list_test_list_add()
60 list_test_list_add_tail(struct kunit *test) list_test_list_add_tail() argument
74 list_test_list_del(struct kunit *test) list_test_list_del() argument
90 list_test_list_replace(struct kunit *test) list_test_list_replace() argument
106 list_test_list_replace_init(struct kunit *test) list_test_list_replace_init() argument
125 list_test_list_swap(struct kunit *test) list_test_list_swap() argument
147 list_test_list_del_init(struct kunit *test) list_test_list_del_init() argument
164 list_test_list_move(struct kunit *test) list_test_list_move() argument
183 list_test_list_move_tail(struct kunit *test) list_test_list_move_tail() argument
202 list_test_list_bulk_move_tail(struct kunit *test) list_test_list_bulk_move_tail() argument
237 list_test_list_is_first(struct kunit *test) list_test_list_is_first() argument
249 list_test_list_is_last(struct kunit *test) list_test_list_is_last() argument
261 list_test_list_empty(struct kunit *test) list_test_list_empty() argument
273 list_test_list_empty_careful(struct kunit *test) list_test_list_empty_careful() argument
286 list_test_list_rotate_left(struct kunit *test) list_test_list_rotate_left() argument
303 list_test_list_rotate_to_front(struct kunit *test) list_test_list_rotate_to_front() argument
327 list_test_list_is_singular(struct kunit *test) list_test_list_is_singular() argument
346 list_test_list_cut_position(struct kunit *test) list_test_list_cut_position() argument
374 list_test_list_cut_before(struct kunit *test) list_test_list_cut_before() argument
402 list_test_list_splice(struct kunit *test) list_test_list_splice() argument
427 list_test_list_splice_tail(struct kunit *test) list_test_list_splice_tail() argument
452 list_test_list_splice_init(struct kunit *test) list_test_list_splice_init() argument
479 list_test_list_splice_tail_init(struct kunit *test) list_test_list_splice_tail_init() argument
506 list_test_list_entry(struct kunit *test) list_test_list_entry() argument
514 list_test_list_first_entry(struct kunit *test) list_test_list_first_entry() argument
527 list_test_list_last_entry(struct kunit *test) list_test_list_last_entry() argument
540 list_test_list_first_entry_or_null(struct kunit *test) list_test_list_first_entry_or_null() argument
556 list_test_list_next_entry(struct kunit *test) list_test_list_next_entry() argument
569 list_test_list_prev_entry(struct kunit *test) list_test_list_prev_entry() argument
582 list_test_list_for_each(struct kunit *test) list_test_list_for_each() argument
600 list_test_list_for_each_prev(struct kunit *test) list_test_list_for_each_prev() argument
618 list_test_list_for_each_safe(struct kunit *test) list_test_list_for_each_safe() argument
639 list_test_list_for_each_prev_safe(struct kunit *test) list_test_list_for_each_prev_safe() argument
659 list_test_list_for_each_entry(struct kunit *test) list_test_list_for_each_entry() argument
680 list_test_list_for_each_entry_reverse(struct kunit *test) list_test_list_for_each_entry_reverse() argument
[all...]
/kernel/linux/linux-6.6/drivers/platform/chrome/
H A Dcros_ec_proto_test.c6 #include <kunit/test.h>
26 static void cros_ec_proto_test_prepare_tx_legacy_normal(struct kunit *test) in cros_ec_proto_test_prepare_tx_legacy_normal() argument
28 struct cros_ec_proto_test_priv *priv = test->priv; in cros_ec_proto_test_prepare_tx_legacy_normal()
45 KUNIT_EXPECT_EQ(test, ret, EC_MSG_TX_PROTO_BYTES + EC_PROTO2_MAX_PARAM_SIZE); in cros_ec_proto_test_prepare_tx_legacy_normal()
46 KUNIT_EXPECT_EQ(test, ec_dev->dout[0], EC_CMD_VERSION0); in cros_ec_proto_test_prepare_tx_legacy_normal()
47 KUNIT_EXPECT_EQ(test, ec_dev->dout[1], EC_CMD_HELLO); in cros_ec_proto_test_prepare_tx_legacy_normal()
48 KUNIT_EXPECT_EQ(test, ec_dev->dout[2], EC_PROTO2_MAX_PARAM_SIZE); in cros_ec_proto_test_prepare_tx_legacy_normal()
49 KUNIT_EXPECT_EQ(test, EC_MSG_TX_HEADER_BYTES, 3); in cros_ec_proto_test_prepare_tx_legacy_normal()
50 KUNIT_EXPECT_EQ(test, ec_dev->dout[EC_MSG_TX_HEADER_BYTES + 0], 0xde); in cros_ec_proto_test_prepare_tx_legacy_normal()
51 KUNIT_EXPECT_EQ(test, ec_de in cros_ec_proto_test_prepare_tx_legacy_normal()
69 cros_ec_proto_test_prepare_tx_legacy_bad_msg_outsize(struct kunit *test) cros_ec_proto_test_prepare_tx_legacy_bad_msg_outsize() argument
84 cros_ec_proto_test_prepare_tx_normal(struct kunit *test) cros_ec_proto_test_prepare_tx_normal() argument
125 cros_ec_proto_test_prepare_tx_bad_msg_outsize(struct kunit *test) cros_ec_proto_test_prepare_tx_bad_msg_outsize() argument
138 cros_ec_proto_test_check_result(struct kunit *test) cros_ec_proto_test_check_result() argument
178 cros_ec_proto_test_query_all_pretest(struct kunit *test) cros_ec_proto_test_query_all_pretest() argument
193 cros_ec_proto_test_query_all_normal(struct kunit *test) cros_ec_proto_test_query_all_normal() argument
347 cros_ec_proto_test_query_all_no_pd_return_error(struct kunit *test) cros_ec_proto_test_query_all_no_pd_return_error() argument
412 cros_ec_proto_test_query_all_no_pd_return0(struct kunit *test) cros_ec_proto_test_query_all_no_pd_return0() argument
477 cros_ec_proto_test_query_all_legacy_normal_v3_return_error(struct kunit *test) cros_ec_proto_test_query_all_legacy_normal_v3_return_error() argument
542 cros_ec_proto_test_query_all_legacy_normal_v3_return0(struct kunit *test) cros_ec_proto_test_query_all_legacy_normal_v3_return0() argument
607 cros_ec_proto_test_query_all_legacy_xfer_error(struct kunit *test) cros_ec_proto_test_query_all_legacy_xfer_error() argument
655 cros_ec_proto_test_query_all_legacy_return_error(struct kunit *test) cros_ec_proto_test_query_all_legacy_return_error() argument
703 cros_ec_proto_test_query_all_legacy_data_error(struct kunit *test) cros_ec_proto_test_query_all_legacy_data_error() argument
756 cros_ec_proto_test_query_all_legacy_return0(struct kunit *test) cros_ec_proto_test_query_all_legacy_return0() argument
804 cros_ec_proto_test_query_all_no_mkbp(struct kunit *test) cros_ec_proto_test_query_all_no_mkbp() argument
897 cros_ec_proto_test_query_all_no_mkbp_return_error(struct kunit *test) cros_ec_proto_test_query_all_no_mkbp_return_error() argument
985 cros_ec_proto_test_query_all_no_mkbp_return0(struct kunit *test) cros_ec_proto_test_query_all_no_mkbp_return0() argument
1073 cros_ec_proto_test_query_all_no_host_sleep(struct kunit *test) cros_ec_proto_test_query_all_no_host_sleep() argument
1179 cros_ec_proto_test_query_all_no_host_sleep_return0(struct kunit *test) cros_ec_proto_test_query_all_no_host_sleep_return0() argument
1286 cros_ec_proto_test_query_all_default_wake_mask_return_error(struct kunit *test) cros_ec_proto_test_query_all_default_wake_mask_return_error() argument
1413 cros_ec_proto_test_query_all_default_wake_mask_return0(struct kunit *test) cros_ec_proto_test_query_all_default_wake_mask_return0() argument
1540 cros_ec_proto_test_cmd_xfer_normal(struct kunit *test) cros_ec_proto_test_cmd_xfer_normal() argument
1600 cros_ec_proto_test_cmd_xfer_excess_msg_insize(struct kunit *test) cros_ec_proto_test_cmd_xfer_excess_msg_insize() argument
1639 cros_ec_proto_test_cmd_xfer_excess_msg_outsize_without_passthru(struct kunit *test) cros_ec_proto_test_cmd_xfer_excess_msg_outsize_without_passthru() argument
1662 cros_ec_proto_test_cmd_xfer_excess_msg_outsize_with_passthru(struct kunit *test) cros_ec_proto_test_cmd_xfer_excess_msg_outsize_with_passthru() argument
1685 cros_ec_proto_test_cmd_xfer_protocol_v3_normal(struct kunit *test) cros_ec_proto_test_cmd_xfer_protocol_v3_normal() argument
1705 cros_ec_proto_test_cmd_xfer_protocol_v3_no_op(struct kunit *test) cros_ec_proto_test_cmd_xfer_protocol_v3_no_op() argument
1722 cros_ec_proto_test_cmd_xfer_protocol_v2_normal(struct kunit *test) cros_ec_proto_test_cmd_xfer_protocol_v2_normal() argument
1742 cros_ec_proto_test_cmd_xfer_protocol_v2_no_op(struct kunit *test) cros_ec_proto_test_cmd_xfer_protocol_v2_no_op() argument
1759 cros_ec_proto_test_cmd_xfer_in_progress_normal(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_normal() argument
1814 cros_ec_proto_test_cmd_xfer_in_progress_retries_eagain(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_retries_eagain() argument
1842 cros_ec_proto_test_cmd_xfer_in_progress_retries_status_processing(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_retries_status_processing() argument
1881 cros_ec_proto_test_cmd_xfer_in_progress_xfer_error(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_xfer_error() argument
1907 cros_ec_proto_test_cmd_xfer_in_progress_return_error(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_return_error() argument
1939 cros_ec_proto_test_cmd_xfer_in_progress_return0(struct kunit *test) cros_ec_proto_test_cmd_xfer_in_progress_return0() argument
1969 cros_ec_proto_test_cmd_xfer_status_normal(struct kunit *test) cros_ec_proto_test_cmd_xfer_status_normal() argument
1989 cros_ec_proto_test_cmd_xfer_status_xfer_error(struct kunit *test) cros_ec_proto_test_cmd_xfer_status_xfer_error() argument
2009 cros_ec_proto_test_cmd_xfer_status_return_error(struct kunit *test) cros_ec_proto_test_cmd_xfer_status_return_error() argument
2057 cros_ec_proto_test_get_next_event_no_mkbp_event(struct kunit *test) cros_ec_proto_test_get_next_event_no_mkbp_event() argument
2105 cros_ec_proto_test_get_next_event_mkbp_event_ec_suspended(struct kunit *test) cros_ec_proto_test_get_next_event_mkbp_event_ec_suspended() argument
2118 cros_ec_proto_test_get_next_event_mkbp_event_version0(struct kunit *test) cros_ec_proto_test_get_next_event_mkbp_event_version0() argument
2167 cros_ec_proto_test_get_next_event_mkbp_event_version2(struct kunit *test) cros_ec_proto_test_get_next_event_mkbp_event_version2() argument
2217 cros_ec_proto_test_get_next_event_mkbp_event_host_event_rtc(struct kunit *test) cros_ec_proto_test_get_next_event_mkbp_event_host_event_rtc() argument
2266 cros_ec_proto_test_get_next_event_mkbp_event_host_event_masked(struct kunit *test) cros_ec_proto_test_get_next_event_mkbp_event_host_event_masked() argument
2316 cros_ec_proto_test_get_host_event_no_mkbp_event(struct kunit *test) cros_ec_proto_test_get_host_event_no_mkbp_event() argument
2328 cros_ec_proto_test_get_host_event_not_host_event(struct kunit *test) cros_ec_proto_test_get_host_event_not_host_event() argument
2341 cros_ec_proto_test_get_host_event_wrong_event_size(struct kunit *test) cros_ec_proto_test_get_host_event_wrong_event_size() argument
2355 cros_ec_proto_test_get_host_event_normal(struct kunit *test) cros_ec_proto_test_get_host_event_normal() argument
2371 cros_ec_proto_test_check_features_cached(struct kunit *test) cros_ec_proto_test_check_features_cached() argument
2393 cros_ec_proto_test_check_features_not_cached(struct kunit *test) cros_ec_proto_test_check_features_not_cached() argument
2446 cros_ec_proto_test_get_sensor_count_normal(struct kunit *test) cros_ec_proto_test_get_sensor_count_normal() argument
2491 cros_ec_proto_test_get_sensor_count_xfer_error(struct kunit *test) cros_ec_proto_test_get_sensor_count_xfer_error() argument
2531 cros_ec_proto_test_get_sensor_count_legacy(struct kunit *test) cros_ec_proto_test_get_sensor_count_legacy() argument
2596 cros_ec_proto_test_ec_cmd(struct kunit *test) cros_ec_proto_test_ec_cmd() argument
2647 cros_ec_proto_test_init(struct kunit *test) cros_ec_proto_test_init() argument
2680 cros_ec_proto_test_exit(struct kunit *test) cros_ec_proto_test_exit() argument
[all...]
/kernel/linux/linux-6.6/lib/
H A Dlist-test.c3 * KUnit test for the Kernel Linked-list structures.
8 #include <kunit/test.h>
18 static void list_test_list_init(struct kunit *test) in list_test_list_init() argument
37 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list1)); in list_test_list_init()
38 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list2)); in list_test_list_init()
39 KUNIT_EXPECT_TRUE(test, list_empty_careful(&list3)); in list_test_list_init()
40 KUNIT_EXPECT_TRUE(test, list_empty_careful(list4)); in list_test_list_init()
41 KUNIT_EXPECT_TRUE(test, list_empty_careful(list5)); in list_test_list_init()
47 static void list_test_list_add(struct kunit *test) in list_test_list_add() argument
56 KUNIT_EXPECT_PTR_EQ(test, lis in list_test_list_add()
61 list_test_list_add_tail(struct kunit *test) list_test_list_add_tail() argument
75 list_test_list_del(struct kunit *test) list_test_list_del() argument
91 list_test_list_replace(struct kunit *test) list_test_list_replace() argument
107 list_test_list_replace_init(struct kunit *test) list_test_list_replace_init() argument
126 list_test_list_swap(struct kunit *test) list_test_list_swap() argument
148 list_test_list_del_init(struct kunit *test) list_test_list_del_init() argument
165 list_test_list_del_init_careful(struct kunit *test) list_test_list_del_init_careful() argument
185 list_test_list_move(struct kunit *test) list_test_list_move() argument
204 list_test_list_move_tail(struct kunit *test) list_test_list_move_tail() argument
223 list_test_list_bulk_move_tail(struct kunit *test) list_test_list_bulk_move_tail() argument
258 list_test_list_is_head(struct kunit *test) list_test_list_is_head() argument
276 list_test_list_is_first(struct kunit *test) list_test_list_is_first() argument
288 list_test_list_is_last(struct kunit *test) list_test_list_is_last() argument
300 list_test_list_empty(struct kunit *test) list_test_list_empty() argument
312 list_test_list_empty_careful(struct kunit *test) list_test_list_empty_careful() argument
325 list_test_list_rotate_left(struct kunit *test) list_test_list_rotate_left() argument
342 list_test_list_rotate_to_front(struct kunit *test) list_test_list_rotate_to_front() argument
366 list_test_list_is_singular(struct kunit *test) list_test_list_is_singular() argument
385 list_test_list_cut_position(struct kunit *test) list_test_list_cut_position() argument
413 list_test_list_cut_before(struct kunit *test) list_test_list_cut_before() argument
441 list_test_list_splice(struct kunit *test) list_test_list_splice() argument
466 list_test_list_splice_tail(struct kunit *test) list_test_list_splice_tail() argument
491 list_test_list_splice_init(struct kunit *test) list_test_list_splice_init() argument
518 list_test_list_splice_tail_init(struct kunit *test) list_test_list_splice_tail_init() argument
545 list_test_list_entry(struct kunit *test) list_test_list_entry() argument
553 list_test_list_entry_is_head(struct kunit *test) list_test_list_entry_is_head() argument
573 list_test_list_first_entry(struct kunit *test) list_test_list_first_entry() argument
586 list_test_list_last_entry(struct kunit *test) list_test_list_last_entry() argument
599 list_test_list_first_entry_or_null(struct kunit *test) list_test_list_first_entry_or_null() argument
615 list_test_list_next_entry(struct kunit *test) list_test_list_next_entry() argument
628 list_test_list_prev_entry(struct kunit *test) list_test_list_prev_entry() argument
641 list_test_list_for_each(struct kunit *test) list_test_list_for_each() argument
659 list_test_list_for_each_prev(struct kunit *test) list_test_list_for_each_prev() argument
677 list_test_list_for_each_safe(struct kunit *test) list_test_list_for_each_safe() argument
698 list_test_list_for_each_prev_safe(struct kunit *test) list_test_list_for_each_prev_safe() argument
718 list_test_list_for_each_entry(struct kunit *test) list_test_list_for_each_entry() argument
739 list_test_list_for_each_entry_reverse(struct kunit *test) list_test_list_for_each_entry_reverse() argument
813 hlist_test_init(struct kunit *test) hlist_test_init() argument
841 hlist_test_unhashed(struct kunit *test) hlist_test_unhashed() argument
863 hlist_test_unhashed_lockless(struct kunit *test) hlist_test_unhashed_lockless() argument
884 hlist_test_del(struct kunit *test) hlist_test_del() argument
900 hlist_test_del_init(struct kunit *test) hlist_test_del_init() argument
921 hlist_test_add(struct kunit *test) hlist_test_add() argument
945 hlist_test_fake(struct kunit *test) hlist_test_fake() argument
960 hlist_test_is_singular_node(struct kunit *test) hlist_test_is_singular_node() argument
976 hlist_test_empty(struct kunit *test) hlist_test_empty() argument
990 hlist_test_move_list(struct kunit *test) hlist_test_move_list() argument
1006 hlist_test_entry(struct kunit *test) hlist_test_entry() argument
1015 hlist_test_entry_safe(struct kunit *test) hlist_test_entry_safe() argument
1028 hlist_test_for_each(struct kunit *test) hlist_test_for_each() argument
1047 hlist_test_for_each_safe(struct kunit *test) hlist_test_for_each_safe() argument
1067 hlist_test_for_each_entry(struct kunit *test) hlist_test_for_each_entry() argument
1090 hlist_test_for_each_entry_continue(struct kunit *test) hlist_test_for_each_entry_continue() argument
1121 hlist_test_for_each_entry_from(struct kunit *test) hlist_test_for_each_entry_from() argument
1149 hlist_test_for_each_entry_safe(struct kunit *test) hlist_test_for_each_entry_safe() argument
1225 klist_test_add_tail(struct kunit *test) klist_test_add_tail() argument
1253 klist_test_add_head(struct kunit *test) klist_test_add_head() argument
1281 klist_test_add_behind(struct kunit *test) klist_test_add_behind() argument
1314 klist_test_add_before(struct kunit *test) klist_test_add_before() argument
1350 klist_test_del_refcount_greater_than_zero(struct kunit *test) klist_test_del_refcount_greater_than_zero() argument
1401 klist_test_del_refcount_zero(struct kunit *test) klist_test_del_refcount_zero() argument
1434 klist_test_remove(struct kunit *test) klist_test_remove() argument
1468 klist_test_node_attached(struct kunit *test) klist_test_node_attached() argument
[all...]
/kernel/linux/linux-6.6/drivers/clk/
H A Dclk_test.c3 * Kunit test for clk rate management
11 #include <kunit/test.h>
167 static int clk_test_init_with_ops(struct kunit *test, const struct clk_ops *ops) in clk_test_init_with_ops() argument
173 ctx = kunit_kzalloc(test, sizeof(*ctx), GFP_KERNEL); in clk_test_init_with_ops()
177 test->priv = ctx; in clk_test_init_with_ops()
190 static int clk_test_init(struct kunit *test) in clk_test_init() argument
192 return clk_test_init_with_ops(test, &clk_dummy_rate_ops); in clk_test_init()
195 static int clk_maximize_test_init(struct kunit *test) in clk_maximize_test_init() argument
197 return clk_test_init_with_ops(test, &clk_dummy_maximize_rate_ops); in clk_maximize_test_init()
200 static int clk_minimize_test_init(struct kunit *test) in clk_minimize_test_init() argument
205 clk_test_exit(struct kunit *test) clk_test_exit() argument
215 clk_test_get_rate(struct kunit *test) clk_test_get_rate() argument
236 clk_test_set_get_rate(struct kunit *test) clk_test_set_get_rate() argument
261 clk_test_set_set_get_rate(struct kunit *test) clk_test_set_set_get_rate() argument
287 clk_test_round_set_get_rate(struct kunit *test) clk_test_round_set_get_rate() argument
330 clk_uncached_test_init(struct kunit *test) clk_uncached_test_init() argument
357 clk_test_uncached_get_rate(struct kunit *test) clk_test_uncached_get_rate() argument
381 clk_test_uncached_set_range(struct kunit *test) clk_test_uncached_set_range() argument
410 clk_test_uncached_updated_rate_set_range(struct kunit *test) clk_test_uncached_updated_rate_set_range() argument
452 clk_multiple_parents_mux_test_init(struct kunit *test) clk_multiple_parents_mux_test_init() argument
491 clk_multiple_parents_mux_test_exit(struct kunit *test) clk_multiple_parents_mux_test_exit() argument
505 clk_test_multiple_parents_mux_get_parent(struct kunit *test) clk_test_multiple_parents_mux_get_parent() argument
523 clk_test_multiple_parents_mux_has_parent(struct kunit *test) clk_test_multiple_parents_mux_has_parent() argument
551 clk_test_multiple_parents_mux_set_range_set_parent_get_rate(struct kunit *test) clk_test_multiple_parents_mux_set_range_set_parent_get_rate() argument
616 clk_orphan_transparent_multiple_parent_mux_test_init(struct kunit *test) clk_orphan_transparent_multiple_parent_mux_test_init() argument
646 clk_orphan_transparent_multiple_parent_mux_test_exit(struct kunit *test) clk_orphan_transparent_multiple_parent_mux_test_exit() argument
659 clk_test_orphan_transparent_multiple_parent_mux_get_parent(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_get_parent() argument
676 clk_test_orphan_transparent_multiple_parent_mux_set_parent(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent() argument
704 clk_test_orphan_transparent_multiple_parent_mux_set_parent_drop_range(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent_drop_range() argument
738 clk_test_orphan_transparent_multiple_parent_mux_set_parent_get_rate(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent_get_rate() argument
769 clk_test_orphan_transparent_multiple_parent_mux_set_parent_put(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent_put() argument
803 clk_test_orphan_transparent_multiple_parent_mux_set_parent_set_range_modified(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent_set_range_modified() argument
836 clk_test_orphan_transparent_multiple_parent_mux_set_parent_set_range_untouched(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_parent_set_range_untouched() argument
873 clk_test_orphan_transparent_multiple_parent_mux_set_range_round_rate(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_range_round_rate() argument
902 clk_test_orphan_transparent_multiple_parent_mux_set_range_set_parent_get_rate(struct kunit *test) clk_test_orphan_transparent_multiple_parent_mux_set_range_set_parent_get_rate() argument
964 clk_single_parent_mux_test_init(struct kunit *test) clk_single_parent_mux_test_init() argument
996 clk_single_parent_mux_test_exit(struct kunit *test) clk_single_parent_mux_test_exit() argument
1009 clk_test_single_parent_mux_get_parent(struct kunit *test) clk_test_single_parent_mux_get_parent() argument
1027 clk_test_single_parent_mux_has_parent(struct kunit *test) clk_test_single_parent_mux_has_parent() argument
1050 clk_test_single_parent_mux_set_range_disjoint_child_last(struct kunit *test) clk_test_single_parent_mux_set_range_disjoint_child_last() argument
1082 clk_test_single_parent_mux_set_range_disjoint_parent_last(struct kunit *test) clk_test_single_parent_mux_set_range_disjoint_parent_last() argument
1111 clk_test_single_parent_mux_set_range_round_rate_parent_only(struct kunit *test) clk_test_single_parent_mux_set_range_round_rate_parent_only() argument
1141 clk_test_single_parent_mux_set_range_round_rate_child_smaller(struct kunit *test) clk_test_single_parent_mux_set_range_round_rate_child_smaller() argument
1179 clk_test_single_parent_mux_set_range_round_rate_parent_smaller(struct kunit *test) clk_test_single_parent_mux_set_range_round_rate_parent_smaller() argument
1236 clk_orphan_transparent_single_parent_mux_test_init(struct kunit *test) clk_orphan_transparent_single_parent_mux_test_init() argument
1279 clk_test_orphan_transparent_parent_mux_set_range(struct kunit *test) clk_test_orphan_transparent_parent_mux_set_range() argument
1329 clk_orphan_two_level_root_last_test_init(struct kunit *test) clk_orphan_two_level_root_last_test_init() argument
1369 clk_orphan_two_level_root_last_test_exit(struct kunit *test) clk_orphan_two_level_root_last_test_exit() argument
1383 clk_orphan_two_level_root_last_test_get_rate(struct kunit *test) clk_orphan_two_level_root_last_test_get_rate() argument
1405 clk_orphan_two_level_root_last_test_set_range(struct kunit *test) clk_orphan_two_level_root_last_test_set_range() argument
1457 clk_range_test_set_range(struct kunit *test) clk_range_test_set_range() argument
1482 clk_range_test_set_range_invalid(struct kunit *test) clk_range_test_set_range_invalid() argument
1501 clk_range_test_multiple_disjoints_range(struct kunit *test) clk_range_test_multiple_disjoints_range() argument
1529 clk_range_test_set_range_round_rate_lower(struct kunit *test) clk_range_test_set_range_round_rate_lower() argument
1554 clk_range_test_set_range_set_rate_lower(struct kunit *test) clk_range_test_set_range_set_rate_lower() argument
1585 clk_range_test_set_range_set_round_rate_consistent_lower(struct kunit *test) clk_range_test_set_range_set_round_rate_consistent_lower() argument
1614 clk_range_test_set_range_round_rate_higher(struct kunit *test) clk_range_test_set_range_round_rate_higher() argument
1639 clk_range_test_set_range_set_rate_higher(struct kunit *test) clk_range_test_set_range_set_rate_higher() argument
1670 clk_range_test_set_range_set_round_rate_consistent_higher(struct kunit *test) clk_range_test_set_range_set_round_rate_consistent_higher() argument
1703 clk_range_test_set_range_get_rate_raised(struct kunit *test) clk_range_test_set_range_get_rate_raised() argument
1735 clk_range_test_set_range_get_rate_lowered(struct kunit *test) clk_range_test_set_range_get_rate_lowered() argument
1795 clk_range_test_set_range_rate_maximized(struct kunit *test) clk_range_test_set_range_rate_maximized() argument
1847 clk_range_test_multiple_set_range_rate_maximized(struct kunit *test) clk_range_test_multiple_set_range_rate_maximized() argument
1906 clk_range_test_multiple_set_range_rate_put_maximized(struct kunit *test) clk_range_test_multiple_set_range_rate_put_maximized() argument
1983 clk_range_test_set_range_rate_minimized(struct kunit *test) clk_range_test_set_range_rate_minimized() argument
2035 clk_range_test_multiple_set_range_rate_minimized(struct kunit *test) clk_range_test_multiple_set_range_rate_minimized() argument
2090 clk_range_test_multiple_set_range_rate_put_minimized(struct kunit *test) clk_range_test_multiple_set_range_rate_put_minimized() argument
2161 clk_leaf_mux_set_rate_parent_test_init(struct kunit *test) clk_leaf_mux_set_rate_parent_test_init() argument
2206 clk_leaf_mux_set_rate_parent_test_exit(struct kunit *test) clk_leaf_mux_set_rate_parent_test_exit() argument
2221 clk_leaf_mux_set_rate_parent_determine_rate(struct kunit *test) clk_leaf_mux_set_rate_parent_determine_rate() argument
2308 clk_mux_notifier_test_init(struct kunit *test) clk_mux_notifier_test_init() argument
2354 clk_mux_notifier_test_exit(struct kunit *test) clk_mux_notifier_test_exit() argument
2372 clk_mux_notifier_set_parent_test(struct kunit *test) clk_mux_notifier_set_parent_test() argument
2422 clk_mux_no_reparent_test_init(struct kunit *test) clk_mux_no_reparent_test_init() argument
2461 clk_mux_no_reparent_test_exit(struct kunit *test) clk_mux_no_reparent_test_exit() argument
2475 clk_mux_no_reparent_round_rate(struct kunit *test) clk_mux_no_reparent_round_rate() argument
2511 clk_mux_no_reparent_set_rate(struct kunit *test) clk_mux_no_reparent_set_rate() argument
[all...]
H A Dclk-gate_test.c3 * Kunit test for clk gate basic type
9 #include <kunit/test.h>
11 static void clk_gate_register_test_dev(struct kunit *test) in clk_gate_register_test_dev() argument
17 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, pdev); in clk_gate_register_test_dev()
21 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, ret); in clk_gate_register_test_dev()
22 KUNIT_EXPECT_STREQ(test, "test_gate", clk_hw_get_name(ret)); in clk_gate_register_test_dev()
23 KUNIT_EXPECT_EQ(test, 0UL, clk_hw_get_flags(ret)); in clk_gate_register_test_dev()
29 static void clk_gate_register_test_parent_names(struct kunit *test) in clk_gate_register_test_parent_names() argument
36 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, parent); in clk_gate_register_test_parent_names()
40 KUNIT_ASSERT_NOT_ERR_OR_NULL(test, re in clk_gate_register_test_parent_names()
47 clk_gate_register_test_parent_data(struct kunit *test) clk_gate_register_test_parent_data() argument
67 clk_gate_register_test_parent_data_legacy(struct kunit *test) clk_gate_register_test_parent_data_legacy() argument
87 clk_gate_register_test_parent_hw(struct kunit *test) clk_gate_register_test_parent_hw() argument
105 clk_gate_register_test_hiword_invalid(struct kunit *test) clk_gate_register_test_hiword_invalid() argument
137 clk_gate_test_alloc_ctx(struct kunit *test) clk_gate_test_alloc_ctx() argument
148 clk_gate_test_parent_rate(struct kunit *test) clk_gate_test_parent_rate() argument
159 clk_gate_test_enable(struct kunit *test) clk_gate_test_enable() argument
176 clk_gate_test_disable(struct kunit *test) clk_gate_test_disable() argument
203 clk_gate_test_init(struct kunit *test) clk_gate_test_init() argument
224 clk_gate_test_exit(struct kunit *test) clk_gate_test_exit() argument
239 clk_gate_test_invert_enable(struct kunit *test) clk_gate_test_invert_enable() argument
256 clk_gate_test_invert_disable(struct kunit *test) clk_gate_test_invert_disable() argument
282 clk_gate_test_invert_init(struct kunit *test) clk_gate_test_invert_init() argument
312 clk_gate_test_hiword_enable(struct kunit *test) clk_gate_test_hiword_enable() argument
329 clk_gate_test_hiword_disable(struct kunit *test) clk_gate_test_hiword_disable() argument
355 clk_gate_test_hiword_init(struct kunit *test) clk_gate_test_hiword_init() argument
384 clk_gate_test_is_enabled(struct kunit *test) clk_gate_test_is_enabled() argument
399 clk_gate_test_is_disabled(struct kunit *test) clk_gate_test_is_disabled() argument
414 clk_gate_test_is_enabled_inverted(struct kunit *test) clk_gate_test_is_enabled_inverted() argument
429 clk_gate_test_is_disabled_inverted(struct kunit *test) clk_gate_test_is_disabled_inverted() argument
[all...]
/kernel/linux/linux-5.10/security/apparmor/
H A Dpolicy_unpack_test.c6 #include <kunit/test.h>
52 struct kunit *test, size_t buf_size) in build_aa_ext_struct()
57 buf = kunit_kzalloc(test, buf_size, GFP_USER); in build_aa_ext_struct()
58 KUNIT_EXPECT_NOT_ERR_OR_NULL(test, buf); in build_aa_ext_struct()
60 e = kunit_kmalloc(test, sizeof(*e), GFP_USER); in build_aa_ext_struct()
61 KUNIT_EXPECT_NOT_ERR_OR_NULL(test, e); in build_aa_ext_struct()
109 static int policy_unpack_test_init(struct kunit *test) in policy_unpack_test_init() argument
114 puf = kunit_kmalloc(test, sizeof(*puf), GFP_USER); in policy_unpack_test_init()
115 KUNIT_EXPECT_NOT_ERR_OR_NULL(test, puf); in policy_unpack_test_init()
118 puf->e = build_aa_ext_struct(puf, test, e_siz in policy_unpack_test_init()
51 build_aa_ext_struct(struct policy_unpack_fixture *puf, struct kunit *test, size_t buf_size) build_aa_ext_struct() argument
124 policy_unpack_test_inbounds_when_inbounds(struct kunit *test) policy_unpack_test_inbounds_when_inbounds() argument
133 policy_unpack_test_inbounds_when_out_of_bounds(struct kunit *test) policy_unpack_test_inbounds_when_out_of_bounds() argument
140 policy_unpack_test_unpack_array_with_null_name(struct kunit *test) policy_unpack_test_unpack_array_with_null_name() argument
154 policy_unpack_test_unpack_array_with_name(struct kunit *test) policy_unpack_test_unpack_array_with_name() argument
169 policy_unpack_test_unpack_array_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_array_out_of_bounds() argument
185 policy_unpack_test_unpack_blob_with_null_name(struct kunit *test) policy_unpack_test_unpack_blob_with_null_name() argument
199 policy_unpack_test_unpack_blob_with_name(struct kunit *test) policy_unpack_test_unpack_blob_with_name() argument
213 policy_unpack_test_unpack_blob_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_blob_out_of_bounds() argument
231 policy_unpack_test_unpack_str_with_null_name(struct kunit *test) policy_unpack_test_unpack_str_with_null_name() argument
244 policy_unpack_test_unpack_str_with_name(struct kunit *test) policy_unpack_test_unpack_str_with_name() argument
256 policy_unpack_test_unpack_str_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_str_out_of_bounds() argument
272 policy_unpack_test_unpack_strdup_with_null_name(struct kunit *test) policy_unpack_test_unpack_strdup_with_null_name() argument
288 policy_unpack_test_unpack_strdup_with_name(struct kunit *test) policy_unpack_test_unpack_strdup_with_name() argument
303 policy_unpack_test_unpack_strdup_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_strdup_out_of_bounds() argument
320 policy_unpack_test_unpack_nameX_with_null_name(struct kunit *test) policy_unpack_test_unpack_nameX_with_null_name() argument
334 policy_unpack_test_unpack_nameX_with_wrong_code(struct kunit *test) policy_unpack_test_unpack_nameX_with_wrong_code() argument
348 policy_unpack_test_unpack_nameX_with_name(struct kunit *test) policy_unpack_test_unpack_nameX_with_name() argument
363 policy_unpack_test_unpack_nameX_with_wrong_name(struct kunit *test) policy_unpack_test_unpack_nameX_with_wrong_name() argument
378 policy_unpack_test_unpack_u16_chunk_basic(struct kunit *test) policy_unpack_test_unpack_u16_chunk_basic() argument
400 policy_unpack_test_unpack_u16_chunk_out_of_bounds_1( struct kunit *test) policy_unpack_test_unpack_u16_chunk_out_of_bounds_1() argument
416 policy_unpack_test_unpack_u16_chunk_out_of_bounds_2( struct kunit *test) policy_unpack_test_unpack_u16_chunk_out_of_bounds_2() argument
438 policy_unpack_test_unpack_u32_with_null_name(struct kunit *test) policy_unpack_test_unpack_u32_with_null_name() argument
454 policy_unpack_test_unpack_u32_with_name(struct kunit *test) policy_unpack_test_unpack_u32_with_name() argument
471 policy_unpack_test_unpack_u32_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_u32_out_of_bounds() argument
488 policy_unpack_test_unpack_u64_with_null_name(struct kunit *test) policy_unpack_test_unpack_u64_with_null_name() argument
504 policy_unpack_test_unpack_u64_with_name(struct kunit *test) policy_unpack_test_unpack_u64_with_name() argument
521 policy_unpack_test_unpack_u64_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_u64_out_of_bounds() argument
538 policy_unpack_test_unpack_X_code_match(struct kunit *test) policy_unpack_test_unpack_X_code_match() argument
547 policy_unpack_test_unpack_X_code_mismatch(struct kunit *test) policy_unpack_test_unpack_X_code_mismatch() argument
556 policy_unpack_test_unpack_X_out_of_bounds(struct kunit *test) policy_unpack_test_unpack_X_out_of_bounds() argument
[all...]
/kernel/linux/linux-6.6/include/kunit/
H A Dtest.h3 * Base unit test (KUnit) API.
37 /* Size of log associated with test. */
56 * enum kunit_status - Type of result for a test or test suite
57 * @KUNIT_SUCCESS: Denotes the test suite has not failed nor been skipped
58 * @KUNIT_FAILURE: Denotes the test has failed.
59 * @KUNIT_SKIPPED: Denotes the test has been skipped.
84 /* Holds attributes for each test case and suite */
90 * struct kunit_case - represents an individual test case.
92 * @run_case: the function representing the actual test cas
307 kunit_set_failure(struct kunit *test) kunit_set_failure() argument
435 kunit_kmalloc(struct kunit *test, size_t size, gfp_t gfp) kunit_kmalloc() argument
455 kunit_kzalloc(struct kunit *test, size_t size, gfp_t gfp) kunit_kzalloc() argument
469 kunit_kcalloc(struct kunit *test, size_t n, size_t size, gfp_t gfp) kunit_kcalloc() argument
[all...]
/kernel/linux/linux-5.10/tools/pci/
H A Dpcitest.c41 static int run_test(struct pci_test *test) in run_test() argument
47 fd = open(test->device, O_RDWR); in run_test()
53 if (test->barnum >= 0 && test->barnum <= 5) { in run_test()
54 ret = ioctl(fd, PCITEST_BAR, test->barnum); in run_test()
55 fprintf(stdout, "BAR%d:\t\t", test->barnum); in run_test()
62 if (test->set_irqtype) { in run_test()
63 ret = ioctl(fd, PCITEST_SET_IRQTYPE, test->irqtype); in run_test()
64 fprintf(stdout, "SET IRQ TYPE TO %s:\t\t", irq[test->irqtype]); in run_test()
71 if (test in run_test()
160 struct pci_test *test; main() local
[all...]
/kernel/linux/linux-6.6/tools/pci/
H A Dpcitest.c41 static int run_test(struct pci_test *test) in run_test() argument
47 fd = open(test->device, O_RDWR); in run_test()
53 if (test->barnum >= 0 && test->barnum <= 5) { in run_test()
54 ret = ioctl(fd, PCITEST_BAR, test->barnum); in run_test()
55 fprintf(stdout, "BAR%d:\t\t", test->barnum); in run_test()
62 if (test->set_irqtype) { in run_test()
63 ret = ioctl(fd, PCITEST_SET_IRQTYPE, test->irqtype); in run_test()
64 fprintf(stdout, "SET IRQ TYPE TO %s:\t\t", irq[test->irqtype]); in run_test()
71 if (test in run_test()
160 struct pci_test *test; main() local
[all...]
/kernel/linux/linux-6.6/drivers/net/ethernet/microchip/vcap/
H A Dvcap_api_kunit.c3 * Microchip VCAP API kunit test suite
6 #include <kunit/test.h>
11 /* First we have the test infrastructure that emulates the platform
246 static void test_vcap_xn_rule_creator(struct kunit *test, int cid, in test_vcap_xn_rule_creator() argument
285 KUNIT_ASSERT_NE(test, VCAP_KFS_NO_VALUE, keyset); in test_vcap_xn_rule_creator()
290 KUNIT_EXPECT_PTR_NE(test, NULL, rule); in test_vcap_xn_rule_creator()
304 KUNIT_EXPECT_EQ(test, 0, ret); in test_vcap_xn_rule_creator()
305 KUNIT_EXPECT_EQ(test, keyset, rule->keyset); in test_vcap_xn_rule_creator()
306 KUNIT_EXPECT_EQ(test, actionset, rule->actionset); in test_vcap_xn_rule_creator()
307 KUNIT_EXPECT_EQ(test, siz in test_vcap_xn_rule_creator()
328 vcap_api_set_bit_1_test(struct kunit *test) vcap_api_set_bit_1_test() argument
345 vcap_api_set_bit_0_test(struct kunit *test) vcap_api_set_bit_0_test() argument
363 vcap_api_iterator_init_test(struct kunit *test) vcap_api_iterator_init_test() argument
392 vcap_api_iterator_next_test(struct kunit *test) vcap_api_iterator_next_test() argument
426 vcap_api_encode_typegroups_test(struct kunit *test) vcap_api_encode_typegroups_test() argument
455 vcap_api_encode_bit_test(struct kunit *test) vcap_api_encode_bit_test() argument
481 vcap_api_encode_field_test(struct kunit *test) vcap_api_encode_field_test() argument
532 vcap_api_encode_short_field_test(struct kunit *test) vcap_api_encode_short_field_test() argument
577 vcap_api_encode_keyfield_test(struct kunit *test) vcap_api_encode_keyfield_test() argument
636 vcap_api_encode_max_keyfield_test(struct kunit *test) vcap_api_encode_max_keyfield_test() argument
703 vcap_api_encode_actionfield_test(struct kunit *test) vcap_api_encode_actionfield_test() argument
750 vcap_api_keyfield_typegroup_test(struct kunit *test) vcap_api_keyfield_typegroup_test() argument
770 vcap_api_actionfield_typegroup_test(struct kunit *test) vcap_api_actionfield_typegroup_test() argument
793 vcap_api_vcap_keyfields_test(struct kunit *test) vcap_api_vcap_keyfields_test() argument
809 vcap_api_vcap_actionfields_test(struct kunit *test) vcap_api_vcap_actionfields_test() argument
823 vcap_api_encode_rule_keyset_test(struct kunit *test) vcap_api_encode_rule_keyset_test() argument
935 vcap_api_encode_rule_actionset_test(struct kunit *test) vcap_api_encode_rule_actionset_test() argument
1007 vcap_api_rule_add_keyvalue_test(struct kunit *test) vcap_api_rule_add_keyvalue_test() argument
1108 vcap_api_rule_add_actionvalue_test(struct kunit *test) vcap_api_rule_add_actionvalue_test() argument
1184 vcap_api_rule_find_keyset_basic_test(struct kunit *test) vcap_api_rule_find_keyset_basic_test() argument
1231 vcap_api_rule_find_keyset_failed_test(struct kunit *test) vcap_api_rule_find_keyset_failed_test() argument
1278 vcap_api_rule_find_keyset_many_test(struct kunit *test) vcap_api_rule_find_keyset_many_test() argument
1330 vcap_api_encode_rule_test(struct kunit *test) vcap_api_encode_rule_test() argument
1459 vcap_api_set_rule_counter_test(struct kunit *test) vcap_api_set_rule_counter_test() argument
1512 vcap_api_get_rule_counter_test(struct kunit *test) vcap_api_get_rule_counter_test() argument
1569 vcap_api_rule_insert_in_order_test(struct kunit *test) vcap_api_rule_insert_in_order_test() argument
1607 vcap_api_rule_insert_reverse_order_test(struct kunit *test) vcap_api_rule_insert_reverse_order_test() argument
1670 vcap_api_rule_remove_at_end_test(struct kunit *test) vcap_api_rule_remove_at_end_test() argument
1742 vcap_api_rule_remove_in_middle_test(struct kunit *test) vcap_api_rule_remove_in_middle_test() argument
1817 vcap_api_rule_remove_in_front_test(struct kunit *test) vcap_api_rule_remove_in_front_test() argument
1880 vcap_api_next_lookup_basic_test(struct kunit *test) vcap_api_next_lookup_basic_test() argument
1926 vcap_api_next_lookup_advanced_test(struct kunit *test) vcap_api_next_lookup_advanced_test() argument
2003 vcap_api_filter_unsupported_keys_test(struct kunit *test) vcap_api_filter_unsupported_keys_test() argument
2070 vcap_api_filter_keylist_test(struct kunit *test) vcap_api_filter_keylist_test() argument
2195 vcap_api_rule_chain_path_test(struct kunit *test) vcap_api_rule_chain_path_test() argument
[all...]
/kernel/linux/linux-5.10/drivers/thunderbolt/
H A Dtest.c9 #include <kunit/test.h>
31 static void kunit_ida_init(struct kunit *test, struct ida *ida) in kunit_ida_init() argument
33 kunit_alloc_resource(test, __ida_init, __ida_destroy, GFP_KERNEL, ida); in kunit_ida_init()
36 static struct tb_switch *alloc_switch(struct kunit *test, u64 route, in alloc_switch() argument
43 sw = kunit_kzalloc(test, sizeof(*sw), GFP_KERNEL); in alloc_switch()
55 sw->ports = kunit_kzalloc(test, size, GFP_KERNEL); in alloc_switch()
64 kunit_ida_init(test, &sw->ports[i].in_hopids); in alloc_switch()
65 kunit_ida_init(test, &sw->ports[i].out_hopids); in alloc_switch()
72 static struct tb_switch *alloc_host(struct kunit *test) in alloc_host() argument
76 sw = alloc_switch(test, in alloc_host()
145 alloc_dev_default(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_default() argument
275 alloc_dev_with_dpin(struct kunit *test, struct tb_switch *parent, u64 route, bool bonded) alloc_dev_with_dpin() argument
296 tb_test_path_basic(struct kunit *test) tb_test_path_basic() argument
313 tb_test_path_not_connected_walk(struct kunit *test) tb_test_path_not_connected_walk() argument
352 tb_test_path_single_hop_walk(struct kunit *test) tb_test_path_single_hop_walk() argument
406 tb_test_path_daisy_chain_walk(struct kunit *test) tb_test_path_daisy_chain_walk() argument
465 tb_test_path_simple_tree_walk(struct kunit *test) tb_test_path_simple_tree_walk() argument
528 tb_test_path_complex_tree_walk(struct kunit *test) tb_test_path_complex_tree_walk() argument
612 tb_test_path_max_length_walk(struct kunit *test) tb_test_path_max_length_walk() argument
715 tb_test_path_not_connected(struct kunit *test) tb_test_path_not_connected() argument
743 tb_test_path_not_bonded_lane0(struct kunit *test) tb_test_path_not_bonded_lane0() argument
801 tb_test_path_not_bonded_lane1(struct kunit *test) tb_test_path_not_bonded_lane1() argument
863 tb_test_path_not_bonded_lane1_chain(struct kunit *test) tb_test_path_not_bonded_lane1_chain() argument
943 tb_test_path_not_bonded_lane1_chain_reverse(struct kunit *test) tb_test_path_not_bonded_lane1_chain_reverse() argument
1023 tb_test_path_mixed_chain(struct kunit *test) tb_test_path_mixed_chain() argument
1115 tb_test_path_mixed_chain_reverse(struct kunit *test) tb_test_path_mixed_chain_reverse() argument
1207 tb_test_tunnel_pcie(struct kunit *test) tb_test_tunnel_pcie() argument
1262 tb_test_tunnel_dp(struct kunit *test) tb_test_tunnel_dp() argument
1300 tb_test_tunnel_dp_chain(struct kunit *test) tb_test_tunnel_dp_chain() argument
1346 tb_test_tunnel_dp_tree(struct kunit *test) tb_test_tunnel_dp_tree() argument
1396 tb_test_tunnel_dp_max_length(struct kunit *test) tb_test_tunnel_dp_max_length() argument
1476 tb_test_tunnel_usb3(struct kunit *test) tb_test_tunnel_usb3() argument
1531 tb_test_tunnel_port_on_path(struct kunit *test) tb_test_tunnel_port_on_path() argument
[all...]
/kernel/linux/linux-6.6/drivers/gpu/drm/ttm/tests/
H A Dttm_pool_test.c30 static int ttm_pool_test_init(struct kunit *test) in ttm_pool_test_init() argument
34 priv = kunit_kzalloc(test, sizeof(*priv), GFP_KERNEL); in ttm_pool_test_init()
35 KUNIT_ASSERT_NOT_NULL(test, priv); in ttm_pool_test_init()
37 priv->devs = ttm_test_devices_basic(test); in ttm_pool_test_init()
38 test->priv = priv; in ttm_pool_test_init()
43 static void ttm_pool_test_fini(struct kunit *test) in ttm_pool_test_fini() argument
45 struct ttm_pool_test_priv *priv = test->priv; in ttm_pool_test_fini()
47 ttm_test_devices_put(test, priv->devs); in ttm_pool_test_fini()
50 static struct ttm_tt *ttm_tt_kunit_init(struct kunit *test, in ttm_tt_kunit_init() argument
55 struct ttm_pool_test_priv *priv = test in ttm_tt_kunit_init()
73 ttm_pool_pre_populated(struct kunit *test, size_t size, enum ttm_caching caching) ttm_pool_pre_populated() argument
135 ttm_pool_alloc_basic(struct kunit *test) ttm_pool_alloc_basic() argument
196 ttm_pool_alloc_basic_dma_addr(struct kunit *test) ttm_pool_alloc_basic_dma_addr() argument
239 ttm_pool_alloc_order_caching_match(struct kunit *test) ttm_pool_alloc_order_caching_match() argument
267 ttm_pool_alloc_caching_mismatch(struct kunit *test) ttm_pool_alloc_caching_mismatch() argument
301 ttm_pool_alloc_order_mismatch(struct kunit *test) ttm_pool_alloc_order_mismatch() argument
335 ttm_pool_free_dma_alloc(struct kunit *test) ttm_pool_free_dma_alloc() argument
366 ttm_pool_free_no_dma_alloc(struct kunit *test) ttm_pool_free_no_dma_alloc() argument
397 ttm_pool_fini_basic(struct kunit *test) ttm_pool_fini_basic() argument
[all...]

Completed in 21 milliseconds

12345678910>>...42