summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/wm8998.c
diff options
context:
space:
mode:
authorCharles Keepax <ckeepax@opensource.wolfsonmicro.com>2017-01-18 16:27:05 +0100
committerMark Brown <broonie@kernel.org>2017-01-18 17:26:56 +0100
commitacff07d060d8175b2b54c5bc2d9bb910a6db1049 (patch)
tree8bbd289f2c3104e9ec2af9e7eff452a0f706b6e6 /sound/soc/codecs/wm8998.c
parentMerge remote-tracking branches 'asoc/topic/wm9712', 'asoc/topic/wm9713' and '... (diff)
downloadlinux-acff07d060d8175b2b54c5bc2d9bb910a6db1049.tar.xz
linux-acff07d060d8175b2b54c5bc2d9bb910a6db1049.zip
ASoC: arizona: Propagate errors from arizona_spk_init
arizona_spk_init uses snd_soc_dapm_new_control which since commit 37e1df8c95e2 ("ASoC: dapm: handle probe deferrals") will occasionally request a probe deferral. Which means we should propagate the error out of our driver from it. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/wm8998.c')
-rw-r--r--sound/soc/codecs/wm8998.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/soc/codecs/wm8998.c b/sound/soc/codecs/wm8998.c
index 3694f5958d86..44f447136e22 100644
--- a/sound/soc/codecs/wm8998.c
+++ b/sound/soc/codecs/wm8998.c
@@ -1321,10 +1321,14 @@ static int wm8998_codec_probe(struct snd_soc_codec *codec)
struct wm8998_priv *priv = snd_soc_codec_get_drvdata(codec);
struct snd_soc_dapm_context *dapm = snd_soc_codec_get_dapm(codec);
struct snd_soc_component *component = snd_soc_dapm_to_component(dapm);
+ int ret;
priv->core.arizona->dapm = dapm;
- arizona_init_spk(codec);
+ ret = arizona_init_spk(codec);
+ if (ret < 0)
+ return ret;
+
arizona_init_gpio(codec);
arizona_init_notifiers(codec);