Lines Matching refs:head

102  * @head:	struct plist_head variable name
104 #define PLIST_HEAD_INIT(head, _lock) \
106 .prio_list = LIST_HEAD_INIT((head).prio_list), \
107 .node_list = LIST_HEAD_INIT((head).node_list), \
126 * @head: &struct plist_head pointer
129 plist_head_init(struct plist_head *head, spinlock_t *lock)
131 INIT_LIST_HEAD(&head->prio_list);
132 INIT_LIST_HEAD(&head->node_list);
134 head->lock = lock;
150 extern void plist_add(struct plist_node *node, struct plist_head *head);
151 extern void plist_del(struct plist_node *node, struct plist_head *head);
157 * @head: the head for your list.
159 #define plist_for_each(pos, head) \
160 list_for_each_entry(pos, &(head)->node_list, plist.node_list)
168 * @head: the head for your list.
170 #define plist_for_each_safe(pos, n, head) \
171 list_for_each_entry_safe(pos, n, &(head)->node_list, plist.node_list)
177 * @head: the head for your list.
180 #define plist_for_each_entry(pos, head, mem) \
181 list_for_each_entry(pos, &(head)->node_list, mem.plist.node_list)
189 * @head: the head for your list.
192 #define plist_for_each_entry_safe(pos, n, head, m) \
193 list_for_each_entry_safe(pos, n, &(head)->node_list, m.plist.node_list)
198 * @head: &struct plist_head pointer
200 static inline int plist_head_empty(const struct plist_head *head)
202 return list_empty(&head->node_list);
225 # define plist_first_entry(head, type, member) \
227 WARN_ON(plist_head_empty(head)); \
228 container_of(plist_first(head), type, member); \
231 # define plist_first_entry(head, type, member) \
232 container_of(plist_first(head), type, member)
238 * @head: the &struct plist_head pointer
242 static inline struct plist_node* plist_first(const struct plist_head *head)
244 return list_entry(head->node_list.next,