diff options
author | Mark Brown <broonie@linaro.org> | 2013-08-13 10:19:52 +0100 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2013-08-13 10:19:52 +0100 |
commit | f2e537425a6eae2d70ece5f62c26611f316b70f9 (patch) | |
tree | c45b18a2f640ebd945a61c601ab3a83d6c1c34b7 /sound/soc | |
parent | 4bd93343124ffe3bdc21c2b485c2668aba6651be (diff) | |
parent | fe581391147cb3d738d961d0f1233d91a9e1113c (diff) | |
download | op-kernel-dev-f2e537425a6eae2d70ece5f62c26611f316b70f9.zip op-kernel-dev-f2e537425a6eae2d70ece5f62c26611f316b70f9.tar.gz |
Merge remote-tracking branch 'asoc/fix/dapm' into asoc-dapm
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/soc-dapm.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c index 7f53d86..662a904 100644 --- a/sound/soc/soc-dapm.c +++ b/sound/soc/soc-dapm.c @@ -813,13 +813,14 @@ static int dapm_new_mux(struct snd_soc_dapm_widget *w) return -EINVAL; } - path = list_first_entry(&w->sources, struct snd_soc_dapm_path, - list_sink); - if (!path) { + if (list_empty(&w->sources)) { dev_err(dapm->dev, "ASoC: mux %s has no paths\n", w->name); return -EINVAL; } + path = list_first_entry(&w->sources, struct snd_soc_dapm_path, + list_sink); + ret = dapm_create_or_share_mixmux_kcontrol(w, 0, path); if (ret < 0) return ret; |