Lines Matching refs:substream
25 struct snd_pcm_substream *substream,
28 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
30 struct snd_dma_buffer *dmab = snd_pcm_get_dma_buf(substream);
31 int stream = substream->stream;
50 snd_pcm_period_elapsed(sps->substream);
61 void snd_sof_pcm_period_elapsed(struct snd_pcm_substream *substream)
63 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
83 schedule_work(&spcm->stream[substream->stream].period_elapsed_work);
123 struct snd_pcm_substream *substream,
127 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
130 struct snd_pcm_runtime *runtime = substream->runtime;
146 if (pcm_ops && pcm_ops->hw_free && spcm->prepared[substream->stream]) {
147 ret = pcm_ops->hw_free(component, substream);
151 spcm->prepared[substream->stream] = false;
155 spcm->pcm.pcm_id, substream->stream);
157 ret = snd_sof_pcm_platform_hw_params(sdev, substream, params, &platform_params);
164 if (!spcm->stream[substream->stream].list) {
166 substream->stream);
173 ret = create_page_table(component, substream, runtime->dma_area,
181 ret = pcm_ops->hw_params(component, substream, params, &platform_params);
186 spcm->prepared[substream->stream] = true;
189 memcpy(&spcm->params[substream->stream], params, sizeof(*params));
195 struct snd_pcm_substream *substream)
197 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
212 spcm->pcm.pcm_id, substream->stream);
214 if (spcm->prepared[substream->stream]) {
217 snd_sof_pcm_platform_trigger(sdev, substream, SNDRV_PCM_TRIGGER_STOP);
221 ret = pcm_ops->hw_free(component, substream);
226 spcm->prepared[substream->stream] = false;
230 ret = snd_sof_pcm_platform_hw_free(sdev, substream);
237 ret = sof_widget_list_free(sdev, spcm, substream->stream);
241 cancel_work_sync(&spcm->stream[substream->stream].period_elapsed_work);
247 struct snd_pcm_substream *substream)
249 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
261 if (spcm->prepared[substream->stream])
265 spcm->pcm.pcm_id, substream->stream);
269 substream, &spcm->params[substream->stream]);
284 struct snd_pcm_substream *substream, int cmd)
286 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
303 spcm->pcm.pcm_id, substream->stream, cmd);
314 if (spcm->stream[substream->stream].suspend_ignored) {
320 spcm->stream[substream->stream].suspend_ignored = false;
329 spcm->stream[substream->stream].d0i3_compatible) {
336 spcm->stream[substream->stream].suspend_ignored = true;
356 snd_sof_pcm_platform_trigger(sdev, substream, cmd);
359 ret = pcm_ops->trigger(component, substream, cmd);
366 snd_sof_pcm_platform_trigger(sdev, substream, cmd);
373 snd_sof_pcm_platform_trigger(sdev, substream, cmd);
381 ret = sof_pcm_stream_free(sdev, substream, spcm, substream->stream, false);
387 struct snd_pcm_substream *substream)
389 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
400 return sof_ops(sdev)->pcm_pointer(sdev, substream);
407 host = bytes_to_frames(substream->runtime,
408 spcm->stream[substream->stream].posn.host_posn);
409 dai = bytes_to_frames(substream->runtime,
410 spcm->stream[substream->stream].posn.dai_posn);
412 trace_sof_pcm_pointer_position(sdev, spcm, substream, host, dai);
418 struct snd_pcm_substream *substream)
420 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
421 struct snd_pcm_runtime *runtime = substream->runtime;
437 spcm->pcm.pcm_id, substream->stream);
440 caps = &spcm->pcm.caps[substream->stream];
468 substream->wait_time = 500;
470 spcm->stream[substream->stream].posn.host_posn = 0;
471 spcm->stream[substream->stream].posn.dai_posn = 0;
472 spcm->stream[substream->stream].substream = substream;
473 spcm->prepared[substream->stream] = false;
475 ret = snd_sof_pcm_platform_open(sdev, substream);
483 struct snd_pcm_substream *substream)
485 struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
499 spcm->pcm.pcm_id, substream->stream);
501 err = snd_sof_pcm_platform_close(sdev, substream);
549 if (!pcm->streams[stream].substream) {
550 dev_err(component->dev, "error: NULL playback substream!\n");
554 snd_pcm_set_managed_buffer(pcm->streams[stream].substream,
571 if (!pcm->streams[stream].substream) {
572 dev_err(component->dev, "error: NULL capture substream!\n");
576 snd_pcm_set_managed_buffer(pcm->streams[stream].substream,
670 struct snd_pcm_substream *substream)
674 return snd_sof_pcm_platform_ack(sdev, substream);
678 struct snd_pcm_substream *substream)
684 return pcm_ops->delay(component, substream);