Lines Matching refs:q
147 struct evtchn_fifo_queue *q, *old_q; in evtchn_fifo_set_pending() local
180 q = &v->evtchn_fifo->queue[evtchn->priority]; in evtchn_fifo_set_pending()
183 if ( q == old_q ) in evtchn_fifo_set_pending()
184 spin_lock_irqsave(&q->lock, flags); in evtchn_fifo_set_pending()
185 else if ( q < old_q ) in evtchn_fifo_set_pending()
187 spin_lock_irqsave(&q->lock, flags); in evtchn_fifo_set_pending()
193 spin_lock(&q->lock); in evtchn_fifo_set_pending()
198 if ( q == &v->evtchn_fifo->queue[evtchn->priority] && in evtchn_fifo_set_pending()
202 if ( q != old_q ) in evtchn_fifo_set_pending()
204 spin_unlock_irqrestore(&q->lock, flags); in evtchn_fifo_set_pending()
254 if ( old_q != q ) in evtchn_fifo_set_pending()
259 lastq.last_priority = q->priority; in evtchn_fifo_set_pending()
263 old_q = q; in evtchn_fifo_set_pending()
277 if ( q->tail ) in evtchn_fifo_set_pending()
279 tail_word = evtchn_fifo_word_from_port(d, q->tail); in evtchn_fifo_set_pending()
283 write_atomic(q->head, port); in evtchn_fifo_set_pending()
284 q->tail = port; in evtchn_fifo_set_pending()
288 if ( q != old_q ) in evtchn_fifo_set_pending()
290 spin_unlock_irqrestore(&q->lock, flags); in evtchn_fifo_set_pending()
294 !guest_test_and_set_bit(d, q->priority, in evtchn_fifo_set_pending()
440 static void init_queue(struct vcpu *v, struct evtchn_fifo_queue *q, in init_queue() argument
443 spin_lock_init(&q->lock); in init_queue()
444 q->priority = i; in init_queue()