Lines Matching refs:cstream
70 struct snd_compr_stream *cstream; member
99 static int sprd_platform_compr_trigger(struct snd_compr_stream *cstream,
104 struct snd_compr_stream *cstream = arg; in sprd_platform_compr_drain_notify() local
105 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_drain_notify()
110 snd_compr_drain_notify(cstream); in sprd_platform_compr_drain_notify()
115 struct snd_compr_stream *cstream = data; in sprd_platform_compr_dma_complete() local
116 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_dma_complete()
125 snd_compr_fragment_elapsed(cstream); in sprd_platform_compr_dma_complete()
128 static int sprd_platform_compr_dma_config(struct snd_compr_stream *cstream, in sprd_platform_compr_dma_config() argument
132 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_dma_config()
134 struct snd_soc_pcm_runtime *rtd = cstream->private_data; in sprd_platform_compr_dma_config()
204 if (cstream->direction == SND_COMPRESS_PLAYBACK) { in sprd_platform_compr_dma_config()
250 dma->desc->callback_param = cstream; in sprd_platform_compr_dma_config()
264 static int sprd_platform_compr_set_params(struct snd_compr_stream *cstream, in sprd_platform_compr_set_params() argument
267 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_set_params()
269 struct snd_soc_pcm_runtime *rtd = cstream->private_data; in sprd_platform_compr_set_params()
282 ret = sprd_platform_compr_dma_config(cstream, params, 1); in sprd_platform_compr_set_params()
288 ret = sprd_platform_compr_dma_config(cstream, params, 0); in sprd_platform_compr_set_params()
294 compr_params.direction = cstream->direction; in sprd_platform_compr_set_params()
302 ret = stream->compr_ops->set_params(cstream->direction, &compr_params); in sprd_platform_compr_set_params()
317 static int sprd_platform_compr_open(struct snd_compr_stream *cstream) in sprd_platform_compr_open() argument
319 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_open()
320 struct snd_soc_pcm_runtime *rtd = cstream->private_data; in sprd_platform_compr_open()
327 int stream_id = cstream->direction, ret; in sprd_platform_compr_open()
337 stream->cstream = cstream; in sprd_platform_compr_open()
375 cb.drain_data = cstream; in sprd_platform_compr_open()
395 static int sprd_platform_compr_free(struct snd_compr_stream *cstream) in sprd_platform_compr_free() argument
397 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_free()
399 struct snd_soc_pcm_runtime *rtd = cstream->private_data; in sprd_platform_compr_free()
403 int stream_id = cstream->direction, i; in sprd_platform_compr_free()
423 static int sprd_platform_compr_trigger(struct snd_compr_stream *cstream, in sprd_platform_compr_trigger() argument
426 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_trigger()
428 struct snd_soc_pcm_runtime *rtd = cstream->private_data; in sprd_platform_compr_trigger()
433 int stream_id = cstream->direction; in sprd_platform_compr_trigger()
435 if (cstream->direction != SND_COMPRESS_PLAYBACK) { in sprd_platform_compr_trigger()
521 static int sprd_platform_compr_pointer(struct snd_compr_stream *cstream, in sprd_platform_compr_pointer() argument
524 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_pointer()
535 static int sprd_platform_compr_copy(struct snd_compr_stream *cstream, in sprd_platform_compr_copy() argument
538 struct snd_compr_runtime *runtime = cstream->runtime; in sprd_platform_compr_copy()
612 static int sprd_platform_compr_get_caps(struct snd_compr_stream *cstream, in sprd_platform_compr_get_caps() argument
615 caps->direction = cstream->direction; in sprd_platform_compr_get_caps()
628 sprd_platform_compr_get_codec_caps(struct snd_compr_stream *cstream, in sprd_platform_compr_get_codec_caps() argument