Lines Matching refs:copy_buf
251 struct f_audio_buf *copy_buf; in f_audio_buffer_alloc() local
253 copy_buf = kzalloc(sizeof *copy_buf, GFP_ATOMIC); in f_audio_buffer_alloc()
254 if (!copy_buf) in f_audio_buffer_alloc()
257 copy_buf->buf = kzalloc(buf_size, GFP_ATOMIC); in f_audio_buffer_alloc()
258 if (!copy_buf->buf) { in f_audio_buffer_alloc()
259 kfree(copy_buf); in f_audio_buffer_alloc()
263 return copy_buf; in f_audio_buffer_alloc()
280 struct f_audio_buf *copy_buf; member
321 struct f_audio_buf *copy_buf = audio->copy_buf; in f_audio_out_ep_complete() local
330 if (!copy_buf) in f_audio_out_ep_complete()
334 if (audio_buf_size - copy_buf->actual < req->actual) { in f_audio_out_ep_complete()
335 list_add_tail(©_buf->list, &audio->play_queue); in f_audio_out_ep_complete()
337 copy_buf = f_audio_buffer_alloc(audio_buf_size); in f_audio_out_ep_complete()
338 if (IS_ERR(copy_buf)) in f_audio_out_ep_complete()
342 memcpy(copy_buf->buf + copy_buf->actual, req->buf, req->actual); in f_audio_out_ep_complete()
343 copy_buf->actual += req->actual; in f_audio_out_ep_complete()
344 audio->copy_buf = copy_buf; in f_audio_out_ep_complete()
589 audio->copy_buf = f_audio_buffer_alloc(audio_buf_size); in f_audio_set_alt()
590 if (IS_ERR(audio->copy_buf)) in f_audio_set_alt()
620 struct f_audio_buf *copy_buf = audio->copy_buf; in f_audio_set_alt() local
621 if (copy_buf) { in f_audio_set_alt()
622 list_add_tail(©_buf->list, in f_audio_set_alt()