aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/omap/omap-abe-twl6040.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/omap/omap-abe-twl6040.c')
-rw-r--r--sound/soc/omap/omap-abe-twl6040.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/sound/soc/omap/omap-abe-twl6040.c b/sound/soc/omap/omap-abe-twl6040.c
index 31ab6fee8943..4388de9b81f2 100644
--- a/sound/soc/omap/omap-abe-twl6040.c
+++ b/sound/soc/omap/omap-abe-twl6040.c
@@ -128,6 +128,9 @@ static const struct snd_soc_dapm_widget twl6040_dapm_widgets[] = {
128 SND_SOC_DAPM_MIC("Main Handset Mic", NULL), 128 SND_SOC_DAPM_MIC("Main Handset Mic", NULL),
129 SND_SOC_DAPM_MIC("Sub Handset Mic", NULL), 129 SND_SOC_DAPM_MIC("Sub Handset Mic", NULL),
130 SND_SOC_DAPM_LINE("Line In", NULL), 130 SND_SOC_DAPM_LINE("Line In", NULL),
131
132 /* Digital microphones */
133 SND_SOC_DAPM_MIC("Digital Mic", NULL),
131}; 134};
132 135
133static const struct snd_soc_dapm_route audio_map[] = { 136static const struct snd_soc_dapm_route audio_map[] = {
@@ -210,10 +213,6 @@ static int omap_abe_twl6040_init(struct snd_soc_pcm_runtime *rtd)
210 return ret; 213 return ret;
211} 214}
212 215
213static const struct snd_soc_dapm_widget dmic_dapm_widgets[] = {
214 SND_SOC_DAPM_MIC("Digital Mic", NULL),
215};
216
217static const struct snd_soc_dapm_route dmic_audio_map[] = { 216static const struct snd_soc_dapm_route dmic_audio_map[] = {
218 {"DMic", NULL, "Digital Mic"}, 217 {"DMic", NULL, "Digital Mic"},
219 {"Digital Mic", NULL, "Digital Mic1 Bias"}, 218 {"Digital Mic", NULL, "Digital Mic1 Bias"},
@@ -223,12 +222,6 @@ static int omap_abe_dmic_init(struct snd_soc_pcm_runtime *rtd)
223{ 222{
224 struct snd_soc_codec *codec = rtd->codec; 223 struct snd_soc_codec *codec = rtd->codec;
225 struct snd_soc_dapm_context *dapm = &codec->dapm; 224 struct snd_soc_dapm_context *dapm = &codec->dapm;
226 int ret;
227
228 ret = snd_soc_dapm_new_controls(dapm, dmic_dapm_widgets,
229 ARRAY_SIZE(dmic_dapm_widgets));
230 if (ret)
231 return ret;
232 225
233 return snd_soc_dapm_add_routes(dapm, dmic_audio_map, 226 return snd_soc_dapm_add_routes(dapm, dmic_audio_map,
234 ARRAY_SIZE(dmic_audio_map)); 227 ARRAY_SIZE(dmic_audio_map));