Lines Matching refs:mq
27 struct msgqueue_entry *mq;
29 if ((mq = msgq->free) != NULL)
30 msgq->free = mq->next;
32 return mq;
36 * Function: void mqe_free(MsgQueue_t *msgq, struct msgqueue_entry *mq)
39 * mq - message queue entry to free
41 static void mqe_free(MsgQueue_t *msgq, struct msgqueue_entry *mq)
43 if (mq) {
44 mq->next = msgq->free;
45 msgq->free = mq;
85 struct msgqueue_entry *mq = msgq->qe;
88 for (mq = msgq->qe; mq; mq = mq->next)
89 length += mq->msg.length;
103 struct msgqueue_entry *mq;
105 for (mq = msgq->qe; mq && msgno; mq = mq->next, msgno--);
107 return mq ? &mq->msg : NULL;
120 struct msgqueue_entry *mq = mqe_alloc(msgq);
123 if (mq) {
129 mq->msg.msg[i] = va_arg(ap, unsigned int);
132 mq->msg.length = length;
133 mq->msg.fifo = 0;
134 mq->next = NULL;
140 *mqp = mq;
143 return mq != NULL;
153 struct msgqueue_entry *mq, *mqnext;
155 for (mq = msgq->qe; mq; mq = mqnext) {
156 mqnext = mq->next;
157 mqe_free(msgq, mq);