]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
soundwire: intel: use asoc_rtd_to_cpu() / asoc_rtd_to_codec() macro for DAI pointer
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Mon, 20 Apr 2020 07:01:01 +0000 (16:01 +0900)
committerMark Brown <broonie@kernel.org>
Mon, 20 Apr 2020 15:32:41 +0000 (16:32 +0100)
Now ALSA SoC needs to use asoc_rtd_to_codec(),
otherwise, it will be compile error.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Acked-By: Vinod Koul <vkoul@kernel.org>
Link: https://lore.kernel.org/r/87y2qqvdxu.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/soundwire/intel.c

index 3c83e76c6bf902420f93eb0e6940edf1b3b08b96..ed8d576bf5dc61830ff19511a938c0d36ee45e99 100644 (file)
@@ -669,11 +669,11 @@ static int sdw_stream_setup(struct snd_pcm_substream *substream,
 
        /* Set stream pointer on all CODEC DAIs */
        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);
                if (ret < 0) {
                        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;
                }
        }