Lines Matching refs:runtime

164 	if (substream->runtime) {  in snd_pcm_lib_preallocate_proc_write()
334 struct snd_pcm_runtime *runtime; in snd_pcm_lib_malloc_pages() local
342 runtime = substream->runtime; in snd_pcm_lib_malloc_pages()
344 if (runtime->dma_buffer_p) { in snd_pcm_lib_malloc_pages()
348 if (runtime->dma_buffer_p->bytes >= size) { in snd_pcm_lib_malloc_pages()
349 runtime->dma_bytes = size; in snd_pcm_lib_malloc_pages()
370 runtime->dma_bytes = size; in snd_pcm_lib_malloc_pages()
386 struct snd_pcm_runtime *runtime; in snd_pcm_lib_free_pages() local
390 runtime = substream->runtime; in snd_pcm_lib_free_pages()
391 if (runtime->dma_area == NULL) in snd_pcm_lib_free_pages()
393 if (runtime->dma_buffer_p != &substream->dma_buffer) { in snd_pcm_lib_free_pages()
395 snd_dma_free_pages(runtime->dma_buffer_p); in snd_pcm_lib_free_pages()
396 kfree(runtime->dma_buffer_p); in snd_pcm_lib_free_pages()
407 struct snd_pcm_runtime *runtime; in _snd_pcm_lib_alloc_vmalloc_buffer() local
411 runtime = substream->runtime; in _snd_pcm_lib_alloc_vmalloc_buffer()
412 if (runtime->dma_area) { in _snd_pcm_lib_alloc_vmalloc_buffer()
413 if (runtime->dma_bytes >= size) in _snd_pcm_lib_alloc_vmalloc_buffer()
415 vfree(runtime->dma_area); in _snd_pcm_lib_alloc_vmalloc_buffer()
417 runtime->dma_area = __vmalloc(size, gfp_flags, PAGE_KERNEL); in _snd_pcm_lib_alloc_vmalloc_buffer()
418 if (!runtime->dma_area) in _snd_pcm_lib_alloc_vmalloc_buffer()
420 runtime->dma_bytes = size; in _snd_pcm_lib_alloc_vmalloc_buffer()
434 struct snd_pcm_runtime *runtime; in snd_pcm_lib_free_vmalloc_buffer() local
438 runtime = substream->runtime; in snd_pcm_lib_free_vmalloc_buffer()
439 vfree(runtime->dma_area); in snd_pcm_lib_free_vmalloc_buffer()
440 runtime->dma_area = NULL; in snd_pcm_lib_free_vmalloc_buffer()
458 return vmalloc_to_page(substream->runtime->dma_area + offset); in snd_pcm_lib_get_vmalloc_page()