Lines Matching refs:head
68 * @head: list head to add it after
70 * Insert a new entry after the specified head.
73 static inline void list_add(struct list_head *new, struct list_head *head)
75 __list_add(new, head, head->next);
81 * @head: list head to add it before
83 * Insert a new entry before the specified head.
86 static inline void list_add_tail(struct list_head *new, struct list_head *head)
88 __list_add(new, head->prev, head);
120 * @head: the head for your list.
127 #define __list_for_each(pos, head) \
128 for (pos = (head)->next; pos != (head); pos = pos->next)
134 * @head: the head for your list.
136 #define list_for_each_safe(pos, n, head) \
137 for (pos = (head)->next, n = pos->next; pos != (head); \
163 * @head: the list to test.
165 static inline int list_empty(const struct list_head *head)
167 return head->next == head;
172 * @head: the list
174 static inline struct list_head *list_first(const struct list_head *head)
176 return list_empty(head) ? NULL : head->next;
182 * @head: the head that will follow our entry
185 struct list_head *head)
188 list_add_tail(list, head);
192 struct list_head *head)
196 struct list_head *at = head->next;
198 first->prev = head;
199 head->next = first;
208 * * @head: the place to add it in the first list.
210 static inline void list_splice(struct list_head *list, struct list_head *head)
213 __list_splice(list, head);