Lines Matching refs:runtime
88 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_prepare() local
89 struct sport_device *sport = runtime->private_data; in bf5xx_pcm_prepare()
90 int period_bytes = frames_to_bytes(runtime, runtime->period_size); in bf5xx_pcm_prepare()
96 period_bytes = period_bytes / runtime->channels * 8; in bf5xx_pcm_prepare()
101 sport_config_tx_dma(sport, runtime->dma_area, in bf5xx_pcm_prepare()
102 runtime->periods, period_bytes); in bf5xx_pcm_prepare()
105 sport_config_rx_dma(sport, runtime->dma_area, in bf5xx_pcm_prepare()
106 runtime->periods, period_bytes); in bf5xx_pcm_prepare()
114 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_trigger() local
115 struct sport_device *sport = runtime->private_data; in bf5xx_pcm_trigger()
144 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_pointer() local
145 struct sport_device *sport = runtime->private_data; in bf5xx_pcm_pointer()
167 frames = bytes_to_frames(substream->runtime, diff); in bf5xx_pcm_pointer()
169 frames = frames * runtime->channels / 8; in bf5xx_pcm_pointer()
179 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_open() local
190 runtime->hw.buffer_bytes_max /= 4; in bf5xx_pcm_open()
192 runtime->hw.info |= SNDRV_PCM_INFO_MMAP; in bf5xx_pcm_open()
194 ret = snd_pcm_hw_constraint_integer(runtime, in bf5xx_pcm_open()
205 runtime->private_data = sport_handle; in bf5xx_pcm_open()
219 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_mmap() local
221 vma->vm_start = (unsigned long)runtime->dma_area; in bf5xx_pcm_mmap()
232 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_copy() local
233 unsigned int sample_size = runtime->sample_bits / 8; in bf5xx_pcm_copy()
243 dst = runtime->dma_area; in bf5xx_pcm_copy()
247 for (i = 0; i < runtime->channels; i++) { in bf5xx_pcm_copy()
255 src = runtime->dma_area; in bf5xx_pcm_copy()
260 for (i = 0; i < runtime->channels; i++) { in bf5xx_pcm_copy()
271 dst = runtime->dma_area; in bf5xx_pcm_copy()
272 dst += frames_to_bytes(runtime, pos); in bf5xx_pcm_copy()
274 src = runtime->dma_area; in bf5xx_pcm_copy()
275 src += frames_to_bytes(runtime, pos); in bf5xx_pcm_copy()
279 memcpy(dst, src, frames_to_bytes(runtime, count)); in bf5xx_pcm_copy()
289 struct snd_pcm_runtime *runtime = substream->runtime; in bf5xx_pcm_silence() local
290 unsigned int sample_size = runtime->sample_bits / 8; in bf5xx_pcm_silence()
291 void *buf = runtime->dma_area; in bf5xx_pcm_silence()
301 offset = frames_to_bytes(runtime, pos); in bf5xx_pcm_silence()
302 samples = count * runtime->channels; in bf5xx_pcm_silence()
305 snd_pcm_format_set_silence(runtime->format, buf + offset, samples); in bf5xx_pcm_silence()