Lines Matching refs:line6midi
29 if (line6->line6midi->substream_receive) in line6_midi_receive()
30 snd_rawmidi_receive(line6->line6midi->substream_receive, in line6_midi_receive()
41 struct snd_line6_midi *line6midi = line6->line6midi; in line6_midi_transmit() local
42 struct midi_buffer *mb = &line6midi->midibuf_out; in line6_midi_transmit()
85 spin_lock_irqsave(&line6->line6midi->lock, flags); in midi_sent()
86 num = --line6->line6midi->num_active_send_urbs; in midi_sent()
89 line6_midi_transmit(line6->line6midi->substream_transmit); in midi_sent()
90 num = line6->line6midi->num_active_send_urbs; in midi_sent()
94 wake_up(&line6->line6midi->send_wait); in midi_sent()
96 spin_unlock_irqrestore(&line6->line6midi->lock, flags); in midi_sent()
137 ++line6->line6midi->num_active_send_urbs; in send_midi_async()
163 line6->line6midi->substream_transmit = substream; in line6_midi_output_trigger()
164 spin_lock_irqsave(&line6->line6midi->lock, flags); in line6_midi_output_trigger()
166 if (line6->line6midi->num_active_send_urbs == 0) in line6_midi_output_trigger()
169 spin_unlock_irqrestore(&line6->line6midi->lock, flags); in line6_midi_output_trigger()
176 struct snd_line6_midi *midi = line6->line6midi; in line6_midi_output_drain()
199 line6->line6midi->substream_receive = substream; in line6_midi_input_trigger()
201 line6->line6midi->substream_receive = NULL; in line6_midi_input_trigger()
246 struct snd_line6_midi *line6midi = rmidi->private_data; in snd_line6_midi_free() local
248 line6_midibuf_destroy(&line6midi->midibuf_in); in snd_line6_midi_free()
249 line6_midibuf_destroy(&line6midi->midibuf_out); in snd_line6_midi_free()
250 kfree(line6midi); in snd_line6_midi_free()
260 struct snd_line6_midi *line6midi; in line6_init_midi() local
271 line6midi = kzalloc(sizeof(struct snd_line6_midi), GFP_KERNEL); in line6_init_midi()
272 if (!line6midi) in line6_init_midi()
275 rmidi->private_data = line6midi; in line6_init_midi()
278 init_waitqueue_head(&line6midi->send_wait); in line6_init_midi()
279 spin_lock_init(&line6midi->lock); in line6_init_midi()
280 line6midi->line6 = line6; in line6_init_midi()
282 err = line6_midibuf_init(&line6midi->midibuf_in, MIDI_BUFFER_SIZE, 0); in line6_init_midi()
286 err = line6_midibuf_init(&line6midi->midibuf_out, MIDI_BUFFER_SIZE, 1); in line6_init_midi()
290 line6->line6midi = line6midi; in line6_init_midi()