Lines Matching full:next
91 list->next = list->prev = list; in INIT_LIST_HEAD()
98 return (head->next == head); in list_empty()
104 struct list_head *next = head->next; in list_empty_careful() local
106 return ((next == head) && (next == head->prev)); in list_empty_careful()
110 __list_del(struct list_head *prev, struct list_head *next) in __list_del() argument
112 next->prev = prev; in __list_del()
113 WRITE_ONCE(prev->next, next); in __list_del()
120 __list_del(entry->prev, entry->next); in __list_del_entry()
127 __list_del(entry->prev, entry->next); in list_del()
133 new->next = old->next; in list_replace()
134 new->next->prev = new; in list_replace()
136 new->prev->next = new; in list_replace()
148 struct list_head *next) in __list_add() argument
151 next->prev = new; in __list_add()
152 new->next = next; in __list_add()
154 prev->next = new; in __list_add()
168 list_entry((ptr)->next, type, member)
177 list_entry(((ptr)->member.next), typeof(*(ptr)), member)
186 for (p = (head)->next; p != (head); p = (p)->next)
189 for (p = (head)->next, n = (p)->next; p != (head); p = n, n = (p)->next)
192 for (p = list_entry((h)->next, typeof(*p), field); &(p)->field != (h); \
193 p = list_entry((p)->field.next, typeof(*p), field))
196 for (p = list_entry((h)->next, typeof(*p), field), \
197 n = list_entry((p)->field.next, typeof(*p), field); &(p)->field != (h);\
198 p = n, n = list_entry(n->field.next, typeof(*n), field))
202 p = list_entry((p)->field.next, typeof(*p), field))
209 for (n = list_entry((pos)->member.next, typeof(*pos), member); \
211 pos = n, n = list_entry(n->member.next, typeof(*n), member))
241 __list_add(new, head, head->next); in list_add()
278 first->prev->next = last->next; in list_bulk_move_tail()
279 last->next->prev = first->prev; in list_bulk_move_tail()
280 head->prev->next = first; in list_bulk_move_tail()
282 last->next = head; in list_bulk_move_tail()
288 struct list_head *next) in linux_list_splice() argument
295 first = list->next; in linux_list_splice()
298 prev->next = first; in linux_list_splice()
299 last->next = next; in linux_list_splice()
300 next->prev = last; in linux_list_splice()
307 linux_list_splice(list, head, head->next); in list_splice()
321 linux_list_splice(list, head, head->next); in list_splice_init()
341 struct hlist_node *next, **pprev; member
348 (node)->next = NULL; \
370 WRITE_ONCE(*(n->pprev), n->next); in hlist_del()
371 if (n->next != NULL) in hlist_del()
372 n->next->pprev = n->pprev; in hlist_del()
389 n->next = h->first; in hlist_add_head()
391 h->first->pprev = &n->next; in hlist_add_head()
397 hlist_add_before(struct hlist_node *n, struct hlist_node *next) in hlist_add_before() argument
400 n->pprev = next->pprev; in hlist_add_before()
401 n->next = next; in hlist_add_before()
402 next->pprev = &n->next; in hlist_add_before()
410 n->next = prev->next; in hlist_add_behind()
411 WRITE_ONCE(prev->next, n); in hlist_add_behind()
412 n->pprev = &prev->next; in hlist_add_behind()
414 if (n->next != NULL) in hlist_add_behind()
415 n->next->pprev = &n->next; in hlist_add_behind()
430 return !list_empty(head) && (head->next == head->prev); in list_is_singular()
436 struct list_head *new_first = entry->next; in __list_cut_position()
437 list->next = head->next; in __list_cut_position()
438 list->next->prev = list; in __list_cut_position()
440 entry->next = list; in __list_cut_position()
441 head->next = new_first; in __list_cut_position()
451 (head->next != entry && head != entry)) in list_cut_position()
469 return list->next == head; in list_is_last()
489 for (p = (head)->first; p; p = (p)->next)
492 for (p = (head)->first; p && ({ n = (p)->next; 1; }); p = n)
500 pos = hlist_entry_safe((pos)->member.next, typeof(*(pos)), member))
503 for (pos = hlist_entry_safe((pos)->member.next, typeof(*(pos)), member); \
505 pos = hlist_entry_safe((pos)->member.next, typeof(*(pos)), member))
509 pos = hlist_entry_safe((pos)->member.next, typeof(*(pos)), member))
513 (pos) && ({ n = (pos)->member.next; 1; }); \