Commit 78091edc authored by Chunxu Li's avatar Chunxu Li Committed by Mark Brown

ASoC: SOF: mediatek: add pcm_hw_params callback for mt8186

add pcm_hw_params callback for mt8186 to support continue
update dma host position
Signed-off-by: default avatarChunxu Li <chunxu.li@mediatek.com>
Link: https://lore.kernel.org/r/20220917022610.594-1-chunxu.li@mediatek.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 5ba3522c
......@@ -460,6 +460,16 @@ static int mt8186_get_bar_index(struct snd_sof_dev *sdev, u32 type)
return type;
}
static int mt8186_pcm_hw_params(struct snd_sof_dev *sdev,
struct snd_pcm_substream *substream,
struct snd_pcm_hw_params *params,
struct snd_sof_platform_stream_params *platform_params)
{
platform_params->cont_update_posn = 1;
return 0;
}
static struct snd_soc_dai_driver mt8186_dai[] = {
{
.name = "SOF_DL1",
......@@ -526,6 +536,7 @@ static struct snd_sof_dsp_ops sof_mt8186_ops = {
/* stream callbacks */
.pcm_open = sof_stream_pcm_open,
.pcm_hw_params = mt8186_pcm_hw_params,
.pcm_close = sof_stream_pcm_close,
/* firmware loading */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment