diff options
author | Takashi Iwai <tiwai@suse.de> | 2014-02-18 04:46:35 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2014-02-22 21:59:08 -0500 |
commit | b13a054aed6f6f3103df14f8bb0f9da4c4edb514 (patch) | |
tree | 27944de7b2b96b600040c302c8eac20d0f0f7dba /sound/soc/codecs/wm8988.c | |
parent | b57efda1f0372d6107ced5a255384be9fd449260 (diff) |
ASoC: wm8988: Use SOC_ENUM_SINGLE_DECL()
Just replace with the helper macro. No functional change at all.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc/codecs/wm8988.c')
-rw-r--r-- | sound/soc/codecs/wm8988.c | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/sound/soc/codecs/wm8988.c b/sound/soc/codecs/wm8988.c index c6e4aba25b77..0277a76c6bef 100644 --- a/sound/soc/codecs/wm8988.c +++ b/sound/soc/codecs/wm8988.c | |||
@@ -126,46 +126,46 @@ struct wm8988_priv { | |||
126 | */ | 126 | */ |
127 | 127 | ||
128 | static const char *bass_boost_txt[] = {"Linear Control", "Adaptive Boost"}; | 128 | static const char *bass_boost_txt[] = {"Linear Control", "Adaptive Boost"}; |
129 | static const struct soc_enum bass_boost = | 129 | static SOC_ENUM_SINGLE_DECL(bass_boost, |
130 | SOC_ENUM_SINGLE(WM8988_BASS, 7, 2, bass_boost_txt); | 130 | WM8988_BASS, 7, bass_boost_txt); |
131 | 131 | ||
132 | static const char *bass_filter_txt[] = { "130Hz @ 48kHz", "200Hz @ 48kHz" }; | 132 | static const char *bass_filter_txt[] = { "130Hz @ 48kHz", "200Hz @ 48kHz" }; |
133 | static const struct soc_enum bass_filter = | 133 | static SOC_ENUM_SINGLE_DECL(bass_filter, |
134 | SOC_ENUM_SINGLE(WM8988_BASS, 6, 2, bass_filter_txt); | 134 | WM8988_BASS, 6, bass_filter_txt); |
135 | 135 | ||
136 | static const char *treble_txt[] = {"8kHz", "4kHz"}; | 136 | static const char *treble_txt[] = {"8kHz", "4kHz"}; |
137 | static const struct soc_enum treble = | 137 | static SOC_ENUM_SINGLE_DECL(treble, |
138 | SOC_ENUM_SINGLE(WM8988_TREBLE, 6, 2, treble_txt); | 138 | WM8988_TREBLE, 6, treble_txt); |
139 | 139 | ||
140 | static const char *stereo_3d_lc_txt[] = {"200Hz", "500Hz"}; | 140 | static const char *stereo_3d_lc_txt[] = {"200Hz", "500Hz"}; |
141 | static const struct soc_enum stereo_3d_lc = | 141 | static SOC_ENUM_SINGLE_DECL(stereo_3d_lc, |
142 | SOC_ENUM_SINGLE(WM8988_3D, 5, 2, stereo_3d_lc_txt); | 142 | WM8988_3D, 5, stereo_3d_lc_txt); |
143 | 143 | ||
144 | static const char *stereo_3d_uc_txt[] = {"2.2kHz", "1.5kHz"}; | 144 | static const char *stereo_3d_uc_txt[] = {"2.2kHz", "1.5kHz"}; |
145 | static const struct soc_enum stereo_3d_uc = | 145 | static SOC_ENUM_SINGLE_DECL(stereo_3d_uc, |
146 | SOC_ENUM_SINGLE(WM8988_3D, 6, 2, stereo_3d_uc_txt); | 146 | WM8988_3D, 6, stereo_3d_uc_txt); |
147 | 147 | ||
148 | static const char *stereo_3d_func_txt[] = {"Capture", "Playback"}; | 148 | static const char *stereo_3d_func_txt[] = {"Capture", "Playback"}; |
149 | static const struct soc_enum stereo_3d_func = | 149 | static SOC_ENUM_SINGLE_DECL(stereo_3d_func, |
150 | SOC_ENUM_SINGLE(WM8988_3D, 7, 2, stereo_3d_func_txt); | 150 | WM8988_3D, 7, stereo_3d_func_txt); |
151 | 151 | ||
152 | static const char *alc_func_txt[] = {"Off", "Right", "Left", "Stereo"}; | 152 | static const char *alc_func_txt[] = {"Off", "Right", "Left", "Stereo"}; |
153 | static const struct soc_enum alc_func = | 153 | static SOC_ENUM_SINGLE_DECL(alc_func, |
154 | SOC_ENUM_SINGLE(WM8988_ALC1, 7, 4, alc_func_txt); | 154 | WM8988_ALC1, 7, alc_func_txt); |
155 | 155 | ||
156 | static const char *ng_type_txt[] = {"Constant PGA Gain", | 156 | static const char *ng_type_txt[] = {"Constant PGA Gain", |
157 | "Mute ADC Output"}; | 157 | "Mute ADC Output"}; |
158 | static const struct soc_enum ng_type = | 158 | static SOC_ENUM_SINGLE_DECL(ng_type, |
159 | SOC_ENUM_SINGLE(WM8988_NGATE, 1, 2, ng_type_txt); | 159 | WM8988_NGATE, 1, ng_type_txt); |
160 | 160 | ||
161 | static const char *deemph_txt[] = {"None", "32Khz", "44.1Khz", "48Khz"}; | 161 | static const char *deemph_txt[] = {"None", "32Khz", "44.1Khz", "48Khz"}; |
162 | static const struct soc_enum deemph = | 162 | static SOC_ENUM_SINGLE_DECL(deemph, |
163 | SOC_ENUM_SINGLE(WM8988_ADCDAC, 1, 4, deemph_txt); | 163 | WM8988_ADCDAC, 1, deemph_txt); |
164 | 164 | ||
165 | static const char *adcpol_txt[] = {"Normal", "L Invert", "R Invert", | 165 | static const char *adcpol_txt[] = {"Normal", "L Invert", "R Invert", |
166 | "L + R Invert"}; | 166 | "L + R Invert"}; |
167 | static const struct soc_enum adcpol = | 167 | static SOC_ENUM_SINGLE_DECL(adcpol, |
168 | SOC_ENUM_SINGLE(WM8988_ADCDAC, 5, 4, adcpol_txt); | 168 | WM8988_ADCDAC, 5, adcpol_txt); |
169 | 169 | ||
170 | static const DECLARE_TLV_DB_SCALE(pga_tlv, -1725, 75, 0); | 170 | static const DECLARE_TLV_DB_SCALE(pga_tlv, -1725, 75, 0); |
171 | static const DECLARE_TLV_DB_SCALE(adc_tlv, -9750, 50, 1); | 171 | static const DECLARE_TLV_DB_SCALE(adc_tlv, -9750, 50, 1); |
@@ -317,16 +317,16 @@ static const struct snd_kcontrol_new wm8988_right_pga_controls = | |||
317 | 317 | ||
318 | /* Differential Mux */ | 318 | /* Differential Mux */ |
319 | static const char *wm8988_diff_sel[] = {"Line 1", "Line 2"}; | 319 | static const char *wm8988_diff_sel[] = {"Line 1", "Line 2"}; |
320 | static const struct soc_enum diffmux = | 320 | static SOC_ENUM_SINGLE_DECL(diffmux, |
321 | SOC_ENUM_SINGLE(WM8988_ADCIN, 8, 2, wm8988_diff_sel); | 321 | WM8988_ADCIN, 8, wm8988_diff_sel); |
322 | static const struct snd_kcontrol_new wm8988_diffmux_controls = | 322 | static const struct snd_kcontrol_new wm8988_diffmux_controls = |
323 | SOC_DAPM_ENUM("Route", diffmux); | 323 | SOC_DAPM_ENUM("Route", diffmux); |
324 | 324 | ||
325 | /* Mono ADC Mux */ | 325 | /* Mono ADC Mux */ |
326 | static const char *wm8988_mono_mux[] = {"Stereo", "Mono (Left)", | 326 | static const char *wm8988_mono_mux[] = {"Stereo", "Mono (Left)", |
327 | "Mono (Right)", "Digital Mono"}; | 327 | "Mono (Right)", "Digital Mono"}; |
328 | static const struct soc_enum monomux = | 328 | static SOC_ENUM_SINGLE_DECL(monomux, |
329 | SOC_ENUM_SINGLE(WM8988_ADCIN, 6, 4, wm8988_mono_mux); | 329 | WM8988_ADCIN, 6, wm8988_mono_mux); |
330 | static const struct snd_kcontrol_new wm8988_monomux_controls = | 330 | static const struct snd_kcontrol_new wm8988_monomux_controls = |
331 | SOC_DAPM_ENUM("Route", monomux); | 331 | SOC_DAPM_ENUM("Route", monomux); |
332 | 332 | ||