Commit a07e8d49 authored by Dong Aisheng's avatar Dong Aisheng Committed by Mark Brown

ASoC: sgtl5000: remove unneeded snd_soc_dapm_new_widgets in probe

There's a driver bug that sgtl5000 dapm widget kcontrols do not work.
e.g. can not select capture mux with amixer tool(no error info prompted).

The root cause is that we still call snd_soc_dapm_new_widgets in
codec driver probe function afer converting to table based widgets.
This will cause the card dapm widgets are instantiated before the
dapm_routes are registered.
Then, no available dapm widget pathes can be found during instantiation
which finally will cause soc_dapm_mux_update_power to fail(can not find
correct path with kcontrol) in snd_soc_dapm_put_enum_double function.

Here we remove the unneeded snd_soc_dapm_new_widgets in codec probe
and let the soc core to handle the register sequence properly.
Then we can fix above issue.
Signed-off-by: default avatarDong Aisheng <dong.aisheng@linaro.org>
Acked-by: default avatarShawn Guo <shawn.guo@linaro.org>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent d0ba4c01
...@@ -1357,8 +1357,6 @@ static int sgtl5000_probe(struct snd_soc_codec *codec) ...@@ -1357,8 +1357,6 @@ static int sgtl5000_probe(struct snd_soc_codec *codec)
if (ret) if (ret)
goto err; goto err;
snd_soc_dapm_new_widgets(&codec->dapm);
return 0; return 0;
err: err:
......
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