/lib/tests/ |
A D | usercopy_kunit.c | 50 struct usercopy_test_priv *priv = test->priv; in usercopy_test_check_nonzero_user() local 52 char *kmem = priv->kmem; in usercopy_test_check_nonzero_user() 53 size_t size = priv->size; in usercopy_test_check_nonzero_user() 109 struct usercopy_test_priv *priv = test->priv; in usercopy_test_copy_struct_from_user() local 111 char *kmem = priv->kmem; in usercopy_test_copy_struct_from_user() 112 size_t size = priv->size; in usercopy_test_copy_struct_from_user() 179 struct usercopy_test_priv *priv = test->priv; in usercopy_test_valid() local 220 struct usercopy_test_priv *priv = test->priv; in usercopy_test_invalid() local 299 priv = kunit_kzalloc(test, sizeof(*priv), GFP_KERNEL); in usercopy_test_init() 301 test->priv = priv; in usercopy_test_init() [all …]
|
A D | test_list_sort.c | 31 struct debug_el **elts = test->priv; in check() 47 static int cmp(void *priv, const struct list_head *a, const struct list_head *b) in cmp() argument 54 check(priv, ela, elb); in cmp() 67 test->priv = elts; in list_sort_test()
|
/lib/kunit/ |
A D | string-stream-test.c | 77 struct string_stream_test_priv *priv = fake_test->priv; in string_stream_destroy_stub() local 81 if (priv->stream_was_freed) in string_stream_destroy_stub() 84 priv->stream_was_freed = true; in string_stream_destroy_stub() 100 struct string_stream_test_priv *priv = test->priv; in string_stream_managed_free_test() local 103 priv->stream_was_freed = false; in string_stream_managed_free_test() 123 struct string_stream_test_priv *priv = test->priv; in string_stream_resource_free_test() local 130 fake_test->priv = priv; in string_stream_resource_free_test() 137 priv->stream_was_freed = false; in string_stream_resource_free_test() 507 priv = kunit_kzalloc(test, sizeof(*priv), GFP_KERNEL); in string_stream_test_init() 508 if (!priv) in string_stream_test_init() [all …]
|
A D | kunit-test.c | 27 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_successful_try() 41 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_try_catch_successful_try_no_catch() 57 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_unsuccessful_try() 67 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_catch() 74 struct kunit_try_catch_test_context *ctx = test->priv; in kunit_test_try_catch_unsuccessful_try_does_catch() 93 test->priv = ctx; in kunit_try_catch_test_init() 187 struct kunit_test_resource_context *ctx = test->priv; in kunit_resource_test_init_resources() 546 test->priv = ctx; in kunit_resource_test_init() 740 static void test_dev_action(void *priv) in test_dev_action() argument 742 *(void **)priv = (void *)1; in test_dev_action() [all …]
|
A D | kunit-example-test.c | 264 KUNIT_ASSERT_NULL(test, test->priv); in example_priv_test() 267 test->priv = kunit_kzalloc(test, 1, GFP_KERNEL); in example_priv_test() 268 KUNIT_EXPECT_NOT_NULL(test, test->priv); in example_priv_test() 269 KUNIT_ASSERT_PTR_EQ(test, test->priv, kunit_get_current_test()->priv); in example_priv_test()
|
A D | test.c | 711 test.priv = NULL; in kunit_run_tests()
|
/lib/ |
A D | sort.c | 151 swap_func(a, b, (int)size, priv); in do_swap() 159 return ((const struct wrapper *)priv)->cmp(a, b); in do_cmp() 160 return cmp(a, b, priv); in do_cmp() 194 const void *priv, in __sort_r() argument 232 do_swap(base, base + n, size, swap_func, priv); in __sort_r() 236 do_swap(base + a, base + n, size, swap_func, priv); in __sort_r() 264 do_swap(base + b, base + c, size, swap_func, priv); in __sort_r() 272 do_swap(base, base + n, size, swap_func, priv); in __sort_r() 274 do_swap(base, base + size, size, swap_func, priv); in __sort_r() 306 const void *priv) in sort_r() argument [all …]
|
A D | list_sort.c | 13 static struct list_head *merge(void *priv, list_cmp_func_t cmp, in merge() argument 20 if (cmp(priv, a, b) <= 0) { in merge() 49 static void merge_final(void *priv, list_cmp_func_t cmp, struct list_head *head, in merge_final() argument 57 if (cmp(priv, a, b) <= 0) { in merge_final() 87 cmp(priv, b, b); in merge_final() 189 void list_sort(void *priv, struct list_head *head, list_cmp_func_t cmp) in list_sort() argument 229 a = merge(priv, cmp, b, a); in list_sort() 251 list = merge(priv, cmp, pending, list); in list_sort() 255 merge_final(priv, cmp, head, pending, list); in list_sort()
|
A D | logic_iomem.c | 19 void *priv; member 113 &mapped_areas[i].priv); in ioremap() 162 area->ops->unmap(area->priv); in iounmap() 166 area->priv = NULL; in iounmap() 226 return (u ## sz) area->ops->read(area->priv, \ 241 area->ops->write(area->priv, \ 267 area->ops->set(area->priv, start, value, size); in memset_io() 272 area->ops->write(area->priv, start + offs, 1, value); in memset_io() 291 area->ops->copy_from(area->priv, buffer, start, size); in memcpy_fromio() 296 buf[offs] = area->ops->read(area->priv, start + offs, 1); in memcpy_fromio() [all …]
|
A D | alloc_tag.c | 50 struct allocinfo_private *priv; in allocinfo_start() local 53 priv = (struct allocinfo_private *)m->private; in allocinfo_start() 56 priv->print_header = true; in allocinfo_start() 57 priv->iter = codetag_get_ct_iter(alloc_tag_cttype); in allocinfo_start() 58 codetag_next_ct(&priv->iter); in allocinfo_start() 60 return priv->iter.ct ? priv : NULL; in allocinfo_start() 66 struct codetag *ct = codetag_next_ct(&priv->iter); in allocinfo_next() 72 return priv; in allocinfo_next() 107 if (priv->print_header) { in allocinfo_show() 109 priv->print_header = false; in allocinfo_show() [all …]
|
A D | parman.c | 52 void *priv; member 65 err = parman->ops->resize(parman->priv, new_count); in parman_enlarge() 80 err = parman->ops->resize(parman->priv, new_count); in parman_shrink() 129 parman->ops->move(parman->priv, item->index, to_index, count); in __parman_prio_move() 267 struct parman *parman_create(const struct parman_ops *ops, void *priv) in parman_create() argument 276 parman->priv = priv; in parman_create()
|
A D | error-inject.c | 21 void *priv; member 66 void *priv) in populate_error_injection_list() argument 89 ent->priv = priv; in populate_error_injection_list() 126 if (ent->priv == mod) { in module_unload_ei_list()
|
A D | test_objagg.c | 99 static void *delta_create(void *priv, void *parent_obj, void *obj) in delta_create() argument 102 struct world *world = priv; in delta_create() 107 if (!delta_check(priv, parent_obj, obj)) in delta_create() 118 static void delta_destroy(void *priv, void *delta_priv) in delta_destroy() argument 121 struct world *world = priv; in delta_destroy() 127 static void *root_create(void *priv, void *obj, unsigned int id) in root_create() argument 129 struct world *world = priv; in root_create() 142 static void root_destroy(void *priv, void *root_priv) in root_destroy() argument 145 struct world *world = priv; in root_destroy() 280 static bool delta_check_dummy(void *priv, const void *parent_obj, in delta_check_dummy() argument [all …]
|
A D | objagg.c | 45 void *priv; member 173 delta_priv = objagg->ops->delta_create(objagg->priv, parent->obj, in objagg_obj_parent_assign() 220 objagg->ops->delta_destroy(objagg->priv, objagg_obj->delta_priv); in objagg_obj_parent_unassign() 273 objagg_obj->root_priv = objagg->ops->root_create(objagg->priv, in objagg_obj_root_create() 292 objagg->ops->root_destroy(objagg->priv, objagg_obj->root_priv); in objagg_obj_root_destroy() 518 struct objagg_hints *objagg_hints, void *priv) in objagg_create() argument 536 objagg->priv = priv; in objagg_create() 817 if (objagg->ops->delta_check(objagg->priv, in objagg_tmp_graph_create()
|
A D | test_parman.c | 92 static int test_parman_resize(void *priv, unsigned long new_count) in test_parman_resize() argument 94 struct test_parman *test_parman = priv; in test_parman_resize() 113 static void test_parman_move(void *priv, unsigned long from_index, in test_parman_move() argument 116 struct test_parman *test_parman = priv; in test_parman_move()
|
A D | iov_iter.c | 440 size_t len, void *priv, void *priv2) in zero_to_user_iter() argument 447 size_t len, void *priv, void *priv2) in zero_to_iter() argument
|