Lines Matching refs:head
874 xpc_init_fifo_uv(struct xpc_fifo_head_uv *head)
876 head->first = NULL;
877 head->last = NULL;
878 spin_lock_init(&head->lock);
879 head->n_entries = 0;
883 xpc_get_fifo_entry_uv(struct xpc_fifo_head_uv *head)
888 spin_lock_irqsave(&head->lock, irq_flags);
889 first = head->first;
890 if (head->first != NULL) {
891 head->first = first->next;
892 if (head->first == NULL)
893 head->last = NULL;
895 head->n_entries--;
896 BUG_ON(head->n_entries < 0);
900 spin_unlock_irqrestore(&head->lock, irq_flags);
905 xpc_put_fifo_entry_uv(struct xpc_fifo_head_uv *head,
911 spin_lock_irqsave(&head->lock, irq_flags);
912 if (head->last != NULL)
913 head->last->next = last;
915 head->first = last;
916 head->last = last;
917 head->n_entries++;
918 spin_unlock_irqrestore(&head->lock, irq_flags);
922 xpc_n_of_fifo_entries_uv(struct xpc_fifo_head_uv *head)
924 return head->n_entries;