diff options
author | Lars-Peter Clausen <lars@metafoo.de> | 2014-03-01 09:48:15 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-03-02 21:01:48 -0500 |
commit | 98308c825ba856796bf52b3c6d6955e62f1fc45c (patch) | |
tree | 6c6535e44841bab7790233e0de00b91af6b63298 | |
parent | 23d8f2253c5ebe975465a61dd416a35b5ebda4b0 (diff) |
ASoC: pxa: e750_wm9705: Convert to table based DAPM setup
Use table based setup to register the DAPM widgets and routes. This on one hand
makes the code a bit cleaner and on the other hand the board level DAPM elements
get registered in the card's DAPM context rather than in the CODEC's DAPM
context.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r-- | sound/soc/pxa/e750_wm9705.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sound/soc/pxa/e750_wm9705.c b/sound/soc/pxa/e750_wm9705.c index c34e447eb991..ee36aba88063 100644 --- a/sound/soc/pxa/e750_wm9705.c +++ b/sound/soc/pxa/e750_wm9705.c | |||
@@ -85,11 +85,6 @@ static int e750_ac97_init(struct snd_soc_pcm_runtime *rtd) | |||
85 | snd_soc_dapm_nc_pin(dapm, "PCBEEP"); | 85 | snd_soc_dapm_nc_pin(dapm, "PCBEEP"); |
86 | snd_soc_dapm_nc_pin(dapm, "MIC2"); | 86 | snd_soc_dapm_nc_pin(dapm, "MIC2"); |
87 | 87 | ||
88 | snd_soc_dapm_new_controls(dapm, e750_dapm_widgets, | ||
89 | ARRAY_SIZE(e750_dapm_widgets)); | ||
90 | |||
91 | snd_soc_dapm_add_routes(dapm, audio_map, ARRAY_SIZE(audio_map)); | ||
92 | |||
93 | return 0; | 88 | return 0; |
94 | } | 89 | } |
95 | 90 | ||
@@ -119,6 +114,11 @@ static struct snd_soc_card e750 = { | |||
119 | .owner = THIS_MODULE, | 114 | .owner = THIS_MODULE, |
120 | .dai_link = e750_dai, | 115 | .dai_link = e750_dai, |
121 | .num_links = ARRAY_SIZE(e750_dai), | 116 | .num_links = ARRAY_SIZE(e750_dai), |
117 | |||
118 | .dapm_widgets = e750_dapm_widgets, | ||
119 | .num_dapm_widgets = ARRAY_SIZE(e750_dapm_widgets), | ||
120 | .dapm_routes = audio_map, | ||
121 | .num_dapm_routes = ARRAY_SIZE(audio_map), | ||
122 | }; | 122 | }; |
123 | 123 | ||
124 | static struct gpio e750_audio_gpios[] = { | 124 | static struct gpio e750_audio_gpios[] = { |