Home | History | Annotate | Download | only in static

Lines Matching refs:head

29  * on the stack head returned by pop_all.
63 s->head = NULL;
86 s->head = NULL;
90 bool ___cds_lfs_empty_head(const struct cds_lfs_head *head)
92 return head == NULL;
103 return ___cds_lfs_empty_head(uatomic_load(&s._s->head, CMM_RELAXED));
114 * take the RCU read-side lock. Even if "head" changes between two
118 * the head of the stack, ensuring consistency by making sure the new
119 * node->next is the same pointer value as the value replaced as head.
125 * retry if the old head was non-NULL (the value read by the first
126 * uatomic_cmpxchg() is used as old head for the following loop). The
130 * required if we first read the old head value). This design decision
142 struct cds_lfs_head *head = NULL;
147 struct cds_lfs_head *old_head = head;
153 node->next = &head->node;
159 head = uatomic_cmpxchg_mo(&s->head, old_head, new_head,
161 if (old_head == head)
164 return !___cds_lfs_empty_head(head);
195 struct cds_lfs_head *head, *next_head;
198 head = uatomic_load(&s->head, CMM_CONSUME);
199 if (___cds_lfs_empty_head(head))
203 * Read head before head->next. Matches the implicit
207 next = uatomic_load(&head->node.next, CMM_RELAXED);
210 if (uatomic_cmpxchg_mo(&s->head, head, next_head,
211 CMM_SEQ_CST, CMM_SEQ_CST) == head){
213 return &head->node;
215 /* busy-loop if head changed under us */
242 struct cds_lfs_head *head;
250 * prior to each uatomic_cmpxchg, which each write to head, are
254 head = uatomic_xchg_mo(&s->head, NULL, CMM_SEQ_CST);
256 return head;