ASoC: topology: Return an error on complete() failure
authorAmadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Fri, 27 Jan 2023 23:11:08 +0000 (00:11 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 30 Jan 2023 16:56:09 +0000 (16:56 +0000)
Function soc_tplg_dapm_complete() detects an error and logs it, but
doesn't return failure to the caller, fix it by returning the error.

Reviewed-by: Cezary Rojewski <cezary.rojewski@intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Link: https://lore.kernel.org/r/20230127231111.937721-9-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-topology.c

index c35c0c5..08dd55f 100644 (file)
@@ -1563,7 +1563,7 @@ static int soc_tplg_dapm_complete(struct soc_tplg *tplg)
                dev_err(tplg->dev, "ASoC: failed to create new widgets %d\n",
                        ret);
 
-       return 0;
+       return ret;
 }
 
 static int set_stream_info(struct soc_tplg *tplg, struct snd_soc_pcm_stream *stream,