summaryrefslogtreecommitdiff
path: root/sound/soc/sof/topology.c
diff options
context:
space:
mode:
authorRanjani Sridharan <ranjani.sridharan@linux.intel.com>2022-03-07 21:10:58 +0300
committerMark Brown <broonie@kernel.org>2022-03-08 15:27:43 +0300
commitfb763299bd8e075f1e9fb0a1cd296b0400fe8442 (patch)
tree1a2cc673ae56e8818db92e3016bed470408cb524 /sound/soc/sof/topology.c
parentc99b70a2d21ab744bdee7a2ea7ec8a35caba9725 (diff)
downloadlinux-fb763299bd8e075f1e9fb0a1cd296b0400fe8442.tar.xz
ASoC: SOF: topology: remove redundant code
With the change in the commit: "ASoC: SOF: Intel: hda: assign link DMA channel at run-time", there is no need to find the CPU DAI in sof_link_hda_load(). Fixes: bdf4ad3fd01f ('ASoC: SOF: Intel: hda: assign link DMA channel at run-time') Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220307181111.49392-6-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/topology.c')
-rw-r--r--sound/soc/sof/topology.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/sound/soc/sof/topology.c b/sound/soc/sof/topology.c
index add0b3009588..15ec59596300 100644
--- a/sound/soc/sof/topology.c
+++ b/sound/soc/sof/topology.c
@@ -3140,7 +3140,6 @@ static int sof_link_hda_load(struct snd_soc_component *scomp, int index,
{
struct snd_sof_dev *sdev = snd_soc_component_get_drvdata(scomp);
struct snd_soc_tplg_private *private = &cfg->priv;
- struct snd_soc_dai *dai;
u32 size = sizeof(*config);
int ret;
@@ -3161,13 +3160,6 @@ static int sof_link_hda_load(struct snd_soc_component *scomp, int index,
dev_dbg(scomp->dev, "HDA config rate %d channels %d\n",
config->hda.rate, config->hda.channels);
- dai = snd_soc_find_dai(link->cpus);
- if (!dai) {
- dev_err(scomp->dev, "error: failed to find dai %s in %s",
- link->cpus->dai_name, __func__);
- return -EINVAL;
- }
-
config->hda.link_dma_ch = DMA_CHAN_INVALID;
ret = sof_set_dai_config(sdev, size, link, config);