Commit 4eb542cc authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by Mark Brown

soundwire: intel: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointer

Now ALSA SoC needs to use asoc_rtd_to_codec(),
otherwise, it will be compile error.
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Acked-By: default avatarVinod Koul <vkoul@kernel.org>
Link: https://lore.kernel.org/r/87y2qqvdxu.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent ace105dd
...@@ -669,11 +669,11 @@ static int sdw_stream_setup(struct snd_pcm_substream *substream, ...@@ -669,11 +669,11 @@ static int sdw_stream_setup(struct snd_pcm_substream *substream,
/* Set stream pointer on all CODEC DAIs */ /* Set stream pointer on all CODEC DAIs */
for (i = 0; i < rtd->num_codecs; i++) { for (i = 0; i < rtd->num_codecs; i++) {
ret = snd_soc_dai_set_sdw_stream(rtd->codec_dais[i], sdw_stream, ret = snd_soc_dai_set_sdw_stream(asoc_rtd_to_codec(rtd, i), sdw_stream,
substream->stream); substream->stream);
if (ret < 0) { if (ret < 0) {
dev_err(dai->dev, "failed to set stream pointer on codec dai %s", dev_err(dai->dev, "failed to set stream pointer on codec dai %s",
rtd->codec_dais[i]->name); asoc_rtd_to_codec(rtd, i)->name);
goto release_stream; goto release_stream;
} }
} }
......
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