Commit 261edc70 authored by Nariman Poushin's avatar Nariman Poushin Committed by Mark Brown

ASoC: core: Fail probe if we fail to add dai widgets

Signed-off-by: default avatarNariman Poushin <nariman@opensource.wolfsonmicro.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent c9eaa447
......@@ -1132,8 +1132,15 @@ static int soc_probe_codec(struct snd_soc_card *card,
driver->num_dapm_widgets);
/* Create DAPM widgets for each DAI stream */
list_for_each_entry(dai, &codec->component.dai_list, list)
snd_soc_dapm_new_dai_widgets(&codec->dapm, dai);
list_for_each_entry(dai, &codec->component.dai_list, list) {
ret = snd_soc_dapm_new_dai_widgets(&codec->dapm, dai);
if (ret != 0) {
dev_err(codec->dev,
"Failed to create DAI widgets %d\n", ret);
goto err_probe;
}
}
codec->dapm.idle_bias_off = driver->idle_bias_off;
......
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