Lines Matching refs:midiq
151 struct midi_queue *midiq;
160 if ((midiq = kmalloc(sizeof(struct midi_queue), GFP_ATOMIC)) == NULL) {
165 midiq->next = NULL;
166 midiq->qtype = 1;
167 midiq->length = midihdr->bufferlength;
168 midiq->sizeLeft = midihdr->bufferlength;
169 midiq->midibyte = midihdr->data;
170 midiq->refdata = (unsigned long) midihdr;
175 card_mpuin->firstmidiq = midiq;
176 card_mpuin->lastmidiq = midiq;
178 (card_mpuin->lastmidiq)->next = midiq;
179 card_mpuin->lastmidiq = midiq;
226 struct midi_queue *midiq;
238 midiq = card_mpuin->firstmidiq;
239 if (midiq != NULL) {
240 if (midiq->sizeLeft == midiq->length)
241 midiq = NULL;
243 card_mpuin->firstmidiq = midiq->next;
251 if (midiq) {
252 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGERROR, (unsigned long) midiq, 0);
253 kfree(midiq);
266 struct midi_queue *midiq;
273 midiq = card_mpuin->firstmidiq;
274 card_mpuin->firstmidiq = midiq->next;
276 if (midiq->sizeLeft == midiq->length)
277 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGDATA, (unsigned long) midiq, 0);
279 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGERROR, (unsigned long) midiq, 0);
281 kfree(midiq);
296 struct midi_queue *midiq;
316 midiq = (struct midi_queue *) data;
317 midihdr = (struct midi_hdr *) midiq->refdata;
319 callback_msg[1] = midiq->length - midiq->sizeLeft;
320 callback_msg[2] = midiq->refdata;
324 midihdr->bytesrecorded = midiq->length - midiq->sizeLeft;
343 data = card_mpuin->midiq[idx].data;
344 card_mpuin->timein = card_mpuin->midiq[idx].timein;
376 card_mpuin->midiq[idx].data = MPUIvalue;
377 card_mpuin->midiq[idx].timein = (jiffies * 1000) / HZ;
439 struct midi_queue *midiq;
441 midiq = card_mpuin->firstmidiq;
442 *midiq->midibyte = data;
443 --midiq->sizeLeft;
444 ++midiq->midibyte;
739 struct midi_queue *midiq;
741 midiq = card_mpuin->firstmidiq;
742 *midiq->midibyte = data;
743 --midiq->sizeLeft;
744 ++midiq->midibyte;
748 card_mpuin->firstmidiq = midiq->next;
754 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGERROR, (unsigned long) midiq, 0);
756 kfree(midiq);
763 struct midi_queue *midiq;
765 midiq = card_mpuin->firstmidiq;
766 *midiq->midibyte = data;
767 --midiq->sizeLeft;
768 ++midiq->midibyte;
778 struct midi_queue *midiq;
780 midiq = card_mpuin->firstmidiq;
784 card_mpuin->firstmidiq = midiq->next;
790 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGDATA, (unsigned long) midiq, 0);
792 kfree(midiq);
799 struct midi_queue *midiq;
801 midiq = card_mpuin->firstmidiq;
803 if (midiq->sizeLeft == 0) {
808 card_mpuin->firstmidiq = midiq->next;
814 emu10k1_mpuin_callback(card_mpuin, ICARDMIDI_INLONGDATA, (unsigned long) midiq, 0);
816 kfree(midiq);