Lines Matching full:entries
386 struct list_head entries[3], *cur; in list_test_list_cut_position() local
391 list_add_tail(&entries[0], &list1); in list_test_list_cut_position()
392 list_add_tail(&entries[1], &list1); in list_test_list_cut_position()
393 list_add_tail(&entries[2], &list1); in list_test_list_cut_position()
395 /* before: [list1] -> entries[0] -> entries[1] -> entries[2] */ in list_test_list_cut_position()
396 list_cut_position(&list2, &list1, &entries[1]); in list_test_list_cut_position()
397 /* after: [list2] -> entries[0] -> entries[1], [list1] -> entries[2] */ in list_test_list_cut_position()
400 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_cut_position()
407 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_cut_position()
414 struct list_head entries[3], *cur; in list_test_list_cut_before() local
419 list_add_tail(&entries[0], &list1); in list_test_list_cut_before()
420 list_add_tail(&entries[1], &list1); in list_test_list_cut_before()
421 list_add_tail(&entries[2], &list1); in list_test_list_cut_before()
423 /* before: [list1] -> entries[0] -> entries[1] -> entries[2] */ in list_test_list_cut_before()
424 list_cut_before(&list2, &list1, &entries[1]); in list_test_list_cut_before()
425 /* after: [list2] -> entries[0], [list1] -> entries[1] -> entries[2] */ in list_test_list_cut_before()
428 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_cut_before()
435 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_cut_before()
442 struct list_head entries[5], *cur; in list_test_list_splice() local
447 list_add_tail(&entries[0], &list1); in list_test_list_splice()
448 list_add_tail(&entries[1], &list1); in list_test_list_splice()
449 list_add_tail(&entries[2], &list2); in list_test_list_splice()
450 list_add_tail(&entries[3], &list2); in list_test_list_splice()
451 list_add_tail(&entries[4], &list1); in list_test_list_splice()
454 list_splice(&list2, &entries[1]); in list_test_list_splice()
458 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_splice()
467 struct list_head entries[5], *cur; in list_test_list_splice_tail() local
472 list_add_tail(&entries[0], &list1); in list_test_list_splice_tail()
473 list_add_tail(&entries[1], &list1); in list_test_list_splice_tail()
474 list_add_tail(&entries[2], &list2); in list_test_list_splice_tail()
475 list_add_tail(&entries[3], &list2); in list_test_list_splice_tail()
476 list_add_tail(&entries[4], &list1); in list_test_list_splice_tail()
479 list_splice_tail(&list2, &entries[4]); in list_test_list_splice_tail()
483 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_splice_tail()
492 struct list_head entries[5], *cur; in list_test_list_splice_init() local
497 list_add_tail(&entries[0], &list1); in list_test_list_splice_init()
498 list_add_tail(&entries[1], &list1); in list_test_list_splice_init()
499 list_add_tail(&entries[2], &list2); in list_test_list_splice_init()
500 list_add_tail(&entries[3], &list2); in list_test_list_splice_init()
501 list_add_tail(&entries[4], &list1); in list_test_list_splice_init()
504 list_splice_init(&list2, &entries[1]); in list_test_list_splice_init()
508 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_splice_init()
519 struct list_head entries[5], *cur; in list_test_list_splice_tail_init() local
524 list_add_tail(&entries[0], &list1); in list_test_list_splice_tail_init()
525 list_add_tail(&entries[1], &list1); in list_test_list_splice_tail_init()
526 list_add_tail(&entries[2], &list2); in list_test_list_splice_tail_init()
527 list_add_tail(&entries[3], &list2); in list_test_list_splice_tail_init()
528 list_add_tail(&entries[4], &list1); in list_test_list_splice_tail_init()
531 list_splice_tail_init(&list2, &entries[4]); in list_test_list_splice_tail_init()
535 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_splice_tail_init()
642 struct list_head entries[3], *cur; in list_test_list_for_each() local
646 list_add_tail(&entries[0], &list); in list_test_list_for_each()
647 list_add_tail(&entries[1], &list); in list_test_list_for_each()
648 list_add_tail(&entries[2], &list); in list_test_list_for_each()
651 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_for_each()
660 struct list_head entries[3], *cur; in list_test_list_for_each_prev() local
664 list_add_tail(&entries[0], &list); in list_test_list_for_each_prev()
665 list_add_tail(&entries[1], &list); in list_test_list_for_each_prev()
666 list_add_tail(&entries[2], &list); in list_test_list_for_each_prev()
669 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_for_each_prev()
678 struct list_head entries[3], *cur, *n; in list_test_list_for_each_safe() local
683 list_add_tail(&entries[0], &list); in list_test_list_for_each_safe()
684 list_add_tail(&entries[1], &list); in list_test_list_for_each_safe()
685 list_add_tail(&entries[2], &list); in list_test_list_for_each_safe()
688 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_for_each_safe()
689 list_del(&entries[i]); in list_test_list_for_each_safe()
699 struct list_head entries[3], *cur, *n; in list_test_list_for_each_prev_safe() local
703 list_add_tail(&entries[0], &list); in list_test_list_for_each_prev_safe()
704 list_add_tail(&entries[1], &list); in list_test_list_for_each_prev_safe()
705 list_add_tail(&entries[2], &list); in list_test_list_for_each_prev_safe()
708 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in list_test_list_for_each_prev_safe()
709 list_del(&entries[i]); in list_test_list_for_each_prev_safe()
719 struct list_test_struct entries[5], *cur; in list_test_list_for_each_entry() local
724 entries[i].data = i; in list_test_list_for_each_entry()
725 list_add_tail(&entries[i].list, &list); in list_test_list_for_each_entry()
740 struct list_test_struct entries[5], *cur; in list_test_list_for_each_entry_reverse() local
745 entries[i].data = i; in list_test_list_for_each_entry_reverse()
746 list_add_tail(&entries[i].list, &list); in list_test_list_for_each_entry_reverse()
1029 struct hlist_node entries[3], *cur; in hlist_test_for_each() local
1033 hlist_add_head(&entries[0], &list); in hlist_test_for_each()
1034 hlist_add_behind(&entries[1], &entries[0]); in hlist_test_for_each()
1035 hlist_add_behind(&entries[2], &entries[1]); in hlist_test_for_each()
1038 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in hlist_test_for_each()
1048 struct hlist_node entries[3], *cur, *n; in hlist_test_for_each_safe() local
1052 hlist_add_head(&entries[0], &list); in hlist_test_for_each_safe()
1053 hlist_add_behind(&entries[1], &entries[0]); in hlist_test_for_each_safe()
1054 hlist_add_behind(&entries[2], &entries[1]); in hlist_test_for_each_safe()
1057 KUNIT_EXPECT_PTR_EQ(test, cur, &entries[i]); in hlist_test_for_each_safe()
1058 hlist_del(&entries[i]); in hlist_test_for_each_safe()
1068 struct hlist_test_struct entries[5], *cur; in hlist_test_for_each_entry() local
1072 entries[0].data = 0; in hlist_test_for_each_entry()
1073 hlist_add_head(&entries[0].list, &list); in hlist_test_for_each_entry()
1075 entries[i].data = i; in hlist_test_for_each_entry()
1076 hlist_add_behind(&entries[i].list, &entries[i-1].list); in hlist_test_for_each_entry()
1091 struct hlist_test_struct entries[5], *cur; in hlist_test_for_each_entry_continue() local
1095 entries[0].data = 0; in hlist_test_for_each_entry_continue()
1096 hlist_add_head(&entries[0].list, &list); in hlist_test_for_each_entry_continue()
1098 entries[i].data = i; in hlist_test_for_each_entry_continue()
1099 hlist_add_behind(&entries[i].list, &entries[i-1].list); in hlist_test_for_each_entry_continue()
1105 cur = &entries[0]; in hlist_test_for_each_entry_continue()
1115 KUNIT_EXPECT_EQ(test, entries[0].data, 0); in hlist_test_for_each_entry_continue()
1117 KUNIT_EXPECT_EQ(test, entries[1].data, 42); in hlist_test_for_each_entry_continue()
1122 struct hlist_test_struct entries[5], *cur; in hlist_test_for_each_entry_from() local
1126 entries[0].data = 0; in hlist_test_for_each_entry_from()
1127 hlist_add_head(&entries[0].list, &list); in hlist_test_for_each_entry_from()
1129 entries[i].data = i; in hlist_test_for_each_entry_from()
1130 hlist_add_behind(&entries[i].list, &entries[i-1].list); in hlist_test_for_each_entry_from()
1135 cur = &entries[0]; in hlist_test_for_each_entry_from()
1145 KUNIT_EXPECT_EQ(test, entries[0].data, 42); in hlist_test_for_each_entry_from()
1150 struct hlist_test_struct entries[5], *cur; in hlist_test_for_each_entry_safe() local
1155 entries[0].data = 0; in hlist_test_for_each_entry_safe()
1156 hlist_add_head(&entries[0].list, &list); in hlist_test_for_each_entry_safe()
1158 entries[i].data = i; in hlist_test_for_each_entry_safe()
1159 hlist_add_behind(&entries[i].list, &entries[i-1].list); in hlist_test_for_each_entry_safe()