Lines Matching refs:runtime
163 if (substream->runtime) { in snd_pcm_lib_preallocate_proc_write()
330 struct snd_pcm_runtime *runtime; in snd_pcm_lib_malloc_pages() local
338 runtime = substream->runtime; in snd_pcm_lib_malloc_pages()
340 if (runtime->dma_buffer_p) { in snd_pcm_lib_malloc_pages()
344 if (runtime->dma_buffer_p->bytes >= size) { in snd_pcm_lib_malloc_pages()
345 runtime->dma_bytes = size; in snd_pcm_lib_malloc_pages()
366 runtime->dma_bytes = size; in snd_pcm_lib_malloc_pages()
381 struct snd_pcm_runtime *runtime; in snd_pcm_lib_free_pages() local
385 runtime = substream->runtime; in snd_pcm_lib_free_pages()
386 if (runtime->dma_area == NULL) in snd_pcm_lib_free_pages()
388 if (runtime->dma_buffer_p != &substream->dma_buffer) { in snd_pcm_lib_free_pages()
390 snd_dma_free_pages(runtime->dma_buffer_p); in snd_pcm_lib_free_pages()
391 kfree(runtime->dma_buffer_p); in snd_pcm_lib_free_pages()
401 struct snd_pcm_runtime *runtime; in _snd_pcm_lib_alloc_vmalloc_buffer() local
405 runtime = substream->runtime; in _snd_pcm_lib_alloc_vmalloc_buffer()
406 if (runtime->dma_area) { in _snd_pcm_lib_alloc_vmalloc_buffer()
407 if (runtime->dma_bytes >= size) in _snd_pcm_lib_alloc_vmalloc_buffer()
409 vfree(runtime->dma_area); in _snd_pcm_lib_alloc_vmalloc_buffer()
411 runtime->dma_area = __vmalloc(size, gfp_flags, PAGE_KERNEL); in _snd_pcm_lib_alloc_vmalloc_buffer()
412 if (!runtime->dma_area) in _snd_pcm_lib_alloc_vmalloc_buffer()
414 runtime->dma_bytes = size; in _snd_pcm_lib_alloc_vmalloc_buffer()
428 struct snd_pcm_runtime *runtime; in snd_pcm_lib_free_vmalloc_buffer() local
432 runtime = substream->runtime; in snd_pcm_lib_free_vmalloc_buffer()
433 vfree(runtime->dma_area); in snd_pcm_lib_free_vmalloc_buffer()
434 runtime->dma_area = NULL; in snd_pcm_lib_free_vmalloc_buffer()
452 return vmalloc_to_page(substream->runtime->dma_area + offset); in snd_pcm_lib_get_vmalloc_page()