Lines Matching refs:head

46 	queue_entry_t head;  member
52 return cq->head == NULL; in circle_queue_empty()
58 return cq->head; in circle_queue_first()
75 return elt->next == cq->head ? NULL : elt->next; in circle_queue_next()
94 queue_entry_t head = circle_queue_first(cq); in circle_enqueue_tail() local
97 if (head == NULL) { in circle_enqueue_tail()
98 cq->head = elt->next = elt->prev = elt; in circle_enqueue_tail()
100 } else if (tail->next != head) { in circle_enqueue_tail()
103 elt->next = head; in circle_enqueue_tail()
106 head->prev = elt; in circle_enqueue_tail()
117 cq->head = elt; in circle_enqueue_head()
130 assert(cq->head == elt); in circle_dequeue()
131 cq->head = NULL; in circle_dequeue()
135 if (cq->head == elt) { in circle_dequeue()
136 cq->head = elt_next; in circle_dequeue()
170 s_head = sq->head; in circle_queue_concat_tail()
178 sq->head = (queue_entry_t)NULL; in circle_queue_concat_tail()
180 d_head = dq->head; in circle_queue_concat_tail()
182 dq->head = s_head; in circle_queue_concat_tail()
203 cq->head = first->next; in circle_queue_rotate_head_forward()
212 cq->head = last; in circle_queue_rotate_head_backward()
245 #define cqe_foreach(qe, head) \ argument
246 for (qe = circle_queue_first(head); qe; qe = circle_queue_next(head, qe))
263 #define cqe_foreach_safe(qe, head) \ argument
264 for (queue_entry_t _ne, _qe = circle_queue_first(head); \
265 (qe = _qe) && (_ne = circle_queue_next(head, _qe), 1); \
283 #define cqe_foreach_element(elt, head, field) \ argument
284 for (queue_entry_t _qe = circle_queue_first(head); \
286 _qe = circle_queue_next(head, _qe))
306 #define cqe_foreach_element_safe(elt, head, field) \ argument
307 for (queue_entry_t _ne, _qe = circle_queue_first(head); \
309 _ne = circle_queue_next(head, _qe), 1); \
313 #define cqe_dequeue_head(head, type, field) ({ \ argument
314 queue_entry_t _tmp_entry = circle_dequeue_head((head)); \
322 #define cqe_dequeue_tail(head, type, field) ({ \ argument
323 queue_entry_t _tmp_entry = circle_dequeue_tail((head)); \
331 #define cqe_queue_first(head, type, field) ({ \ argument
332 queue_entry_t _tmp_entry = circle_queue_first((head)); \
340 #define cqe_queue_next(elt, head, type, field) ({ \ argument
341 queue_entry_t _tmp_entry = circle_queue_next((head), (elt)); \
349 #define cqe_queue_last(head, type, field) ({ \ argument
350 queue_entry_t _tmp_entry = circle_queue_last((head)); \
367 (q)->head = NULL; \