aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/alc5632.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/codecs/alc5632.c')
-rw-r--r--sound/soc/codecs/alc5632.c40
1 files changed, 24 insertions, 16 deletions
diff --git a/sound/soc/codecs/alc5632.c b/sound/soc/codecs/alc5632.c
index fb001c56cf8d..d885056ad8f2 100644
--- a/sound/soc/codecs/alc5632.c
+++ b/sound/soc/codecs/alc5632.c
@@ -293,51 +293,59 @@ static const char * const alc5632_i2s_out_sel[] = {
293 "ADC LR", "Voice Stereo Digital"}; 293 "ADC LR", "Voice Stereo Digital"};
294 294
295/* auxout output mux */ 295/* auxout output mux */
296static const struct soc_enum alc5632_aux_out_input_enum = 296static SOC_ENUM_SINGLE_DECL(alc5632_aux_out_input_enum,
297SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 6, 4, alc5632_aux_out_input_sel); 297 ALC5632_OUTPUT_MIXER_CTRL, 6,
298 alc5632_aux_out_input_sel);
298static const struct snd_kcontrol_new alc5632_auxout_mux_controls = 299static const struct snd_kcontrol_new alc5632_auxout_mux_controls =
299SOC_DAPM_ENUM("AuxOut Mux", alc5632_aux_out_input_enum); 300SOC_DAPM_ENUM("AuxOut Mux", alc5632_aux_out_input_enum);
300 301
301/* speaker output mux */ 302/* speaker output mux */
302static const struct soc_enum alc5632_spkout_input_enum = 303static SOC_ENUM_SINGLE_DECL(alc5632_spkout_input_enum,
303SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 10, 4, alc5632_spkout_input_sel); 304 ALC5632_OUTPUT_MIXER_CTRL, 10,
305 alc5632_spkout_input_sel);
304static const struct snd_kcontrol_new alc5632_spkout_mux_controls = 306static const struct snd_kcontrol_new alc5632_spkout_mux_controls =
305SOC_DAPM_ENUM("SpeakerOut Mux", alc5632_spkout_input_enum); 307SOC_DAPM_ENUM("SpeakerOut Mux", alc5632_spkout_input_enum);
306 308
307/* headphone left output mux */ 309/* headphone left output mux */
308static const struct soc_enum alc5632_hpl_out_input_enum = 310static SOC_ENUM_SINGLE_DECL(alc5632_hpl_out_input_enum,
309SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 9, 2, alc5632_hpl_out_input_sel); 311 ALC5632_OUTPUT_MIXER_CTRL, 9,
312 alc5632_hpl_out_input_sel);
310static const struct snd_kcontrol_new alc5632_hpl_out_mux_controls = 313static const struct snd_kcontrol_new alc5632_hpl_out_mux_controls =
311SOC_DAPM_ENUM("Left Headphone Mux", alc5632_hpl_out_input_enum); 314SOC_DAPM_ENUM("Left Headphone Mux", alc5632_hpl_out_input_enum);
312 315
313/* headphone right output mux */ 316/* headphone right output mux */
314static const struct soc_enum alc5632_hpr_out_input_enum = 317static SOC_ENUM_SINGLE_DECL(alc5632_hpr_out_input_enum,
315SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 8, 2, alc5632_hpr_out_input_sel); 318 ALC5632_OUTPUT_MIXER_CTRL, 8,
319 alc5632_hpr_out_input_sel);
316static const struct snd_kcontrol_new alc5632_hpr_out_mux_controls = 320static const struct snd_kcontrol_new alc5632_hpr_out_mux_controls =
317SOC_DAPM_ENUM("Right Headphone Mux", alc5632_hpr_out_input_enum); 321SOC_DAPM_ENUM("Right Headphone Mux", alc5632_hpr_out_input_enum);
318 322
319/* speaker output N select */ 323/* speaker output N select */
320static const struct soc_enum alc5632_spk_n_sour_enum = 324static SOC_ENUM_SINGLE_DECL(alc5632_spk_n_sour_enum,
321SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 14, 4, alc5632_spk_n_sour_sel); 325 ALC5632_OUTPUT_MIXER_CTRL, 14,
326 alc5632_spk_n_sour_sel);
322static const struct snd_kcontrol_new alc5632_spkoutn_mux_controls = 327static const struct snd_kcontrol_new alc5632_spkoutn_mux_controls =
323SOC_DAPM_ENUM("SpeakerOut N Mux", alc5632_spk_n_sour_enum); 328SOC_DAPM_ENUM("SpeakerOut N Mux", alc5632_spk_n_sour_enum);
324 329
325/* speaker amplifier */ 330/* speaker amplifier */
326static const char *alc5632_amp_names[] = {"AB Amp", "D Amp"}; 331static const char *alc5632_amp_names[] = {"AB Amp", "D Amp"};
327static const struct soc_enum alc5632_amp_enum = 332static SOC_ENUM_SINGLE_DECL(alc5632_amp_enum,
328 SOC_ENUM_SINGLE(ALC5632_OUTPUT_MIXER_CTRL, 13, 2, alc5632_amp_names); 333 ALC5632_OUTPUT_MIXER_CTRL, 13,
334 alc5632_amp_names);
329static const struct snd_kcontrol_new alc5632_amp_mux_controls = 335static const struct snd_kcontrol_new alc5632_amp_mux_controls =
330 SOC_DAPM_ENUM("AB-D Amp Mux", alc5632_amp_enum); 336 SOC_DAPM_ENUM("AB-D Amp Mux", alc5632_amp_enum);
331 337
332/* ADC output select */ 338/* ADC output select */
333static const struct soc_enum alc5632_adcr_func_enum = 339static SOC_ENUM_SINGLE_DECL(alc5632_adcr_func_enum,
334 SOC_ENUM_SINGLE(ALC5632_DAC_FUNC_SELECT, 5, 2, alc5632_adcr_func_sel); 340 ALC5632_DAC_FUNC_SELECT, 5,
341 alc5632_adcr_func_sel);
335static const struct snd_kcontrol_new alc5632_adcr_func_controls = 342static const struct snd_kcontrol_new alc5632_adcr_func_controls =
336 SOC_DAPM_ENUM("ADCR Mux", alc5632_adcr_func_enum); 343 SOC_DAPM_ENUM("ADCR Mux", alc5632_adcr_func_enum);
337 344
338/* I2S out select */ 345/* I2S out select */
339static const struct soc_enum alc5632_i2s_out_enum = 346static SOC_ENUM_SINGLE_DECL(alc5632_i2s_out_enum,
340 SOC_ENUM_SINGLE(ALC5632_I2S_OUT_CTL, 5, 2, alc5632_i2s_out_sel); 347 ALC5632_I2S_OUT_CTL, 5,
348 alc5632_i2s_out_sel);
341static const struct snd_kcontrol_new alc5632_i2s_out_controls = 349static const struct snd_kcontrol_new alc5632_i2s_out_controls =
342 SOC_DAPM_ENUM("I2SOut Mux", alc5632_i2s_out_enum); 350 SOC_DAPM_ENUM("I2SOut Mux", alc5632_i2s_out_enum);
343 351