diff options
-rw-r--r-- | sound/soc/codecs/tlv320dac33.c | 32 |
1 files changed, 13 insertions, 19 deletions
diff --git a/sound/soc/codecs/tlv320dac33.c b/sound/soc/codecs/tlv320dac33.c index 4f358393d6d6..9ce849623a0a 100644 --- a/sound/soc/codecs/tlv320dac33.c +++ b/sound/soc/codecs/tlv320dac33.c | |||
@@ -478,9 +478,7 @@ static const char *dac33_fifo_mode_texts[] = { | |||
478 | "Bypass", "Mode 1", "Mode 7" | 478 | "Bypass", "Mode 1", "Mode 7" |
479 | }; | 479 | }; |
480 | 480 | ||
481 | static const struct soc_enum dac33_fifo_mode_enum = | 481 | static SOC_ENUM_SINGLE_EXT_DECL(dac33_fifo_mode_enum, dac33_fifo_mode_texts); |
482 | SOC_ENUM_SINGLE_EXT(ARRAY_SIZE(dac33_fifo_mode_texts), | ||
483 | dac33_fifo_mode_texts); | ||
484 | 482 | ||
485 | /* L/R Line Output Gain */ | 483 | /* L/R Line Output Gain */ |
486 | static const char *lr_lineout_gain_texts[] = { | 484 | static const char *lr_lineout_gain_texts[] = { |
@@ -488,15 +486,13 @@ static const char *lr_lineout_gain_texts[] = { | |||
488 | "Line 0dB DAC 12dB", "Line 6dB DAC 18dB", | 486 | "Line 0dB DAC 12dB", "Line 6dB DAC 18dB", |
489 | }; | 487 | }; |
490 | 488 | ||
491 | static const struct soc_enum l_lineout_gain_enum = | 489 | static SOC_ENUM_SINGLE_DECL(l_lineout_gain_enum, |
492 | SOC_ENUM_SINGLE(DAC33_LDAC_PWR_CTRL, 0, | 490 | DAC33_LDAC_PWR_CTRL, 0, |
493 | ARRAY_SIZE(lr_lineout_gain_texts), | 491 | lr_lineout_gain_texts); |
494 | lr_lineout_gain_texts); | ||
495 | 492 | ||
496 | static const struct soc_enum r_lineout_gain_enum = | 493 | static SOC_ENUM_SINGLE_DECL(r_lineout_gain_enum, |
497 | SOC_ENUM_SINGLE(DAC33_RDAC_PWR_CTRL, 0, | 494 | DAC33_RDAC_PWR_CTRL, 0, |
498 | ARRAY_SIZE(lr_lineout_gain_texts), | 495 | lr_lineout_gain_texts); |
499 | lr_lineout_gain_texts); | ||
500 | 496 | ||
501 | /* | 497 | /* |
502 | * DACL/R digital volume control: | 498 | * DACL/R digital volume control: |
@@ -534,18 +530,16 @@ static const struct snd_kcontrol_new dac33_dapm_abypassr_control = | |||
534 | /* LOP L/R invert selection */ | 530 | /* LOP L/R invert selection */ |
535 | static const char *dac33_lr_lom_texts[] = {"DAC", "LOP"}; | 531 | static const char *dac33_lr_lom_texts[] = {"DAC", "LOP"}; |
536 | 532 | ||
537 | static const struct soc_enum dac33_left_lom_enum = | 533 | static SOC_ENUM_SINGLE_DECL(dac33_left_lom_enum, |
538 | SOC_ENUM_SINGLE(DAC33_OUT_AMP_CTRL, 3, | 534 | DAC33_OUT_AMP_CTRL, 3, |
539 | ARRAY_SIZE(dac33_lr_lom_texts), | 535 | dac33_lr_lom_texts); |
540 | dac33_lr_lom_texts); | ||
541 | 536 | ||
542 | static const struct snd_kcontrol_new dac33_dapm_left_lom_control = | 537 | static const struct snd_kcontrol_new dac33_dapm_left_lom_control = |
543 | SOC_DAPM_ENUM("Route", dac33_left_lom_enum); | 538 | SOC_DAPM_ENUM("Route", dac33_left_lom_enum); |
544 | 539 | ||
545 | static const struct soc_enum dac33_right_lom_enum = | 540 | static SOC_ENUM_SINGLE_DECL(dac33_right_lom_enum, |
546 | SOC_ENUM_SINGLE(DAC33_OUT_AMP_CTRL, 2, | 541 | DAC33_OUT_AMP_CTRL, 2, |
547 | ARRAY_SIZE(dac33_lr_lom_texts), | 542 | dac33_lr_lom_texts); |
548 | dac33_lr_lom_texts); | ||
549 | 543 | ||
550 | static const struct snd_kcontrol_new dac33_dapm_right_lom_control = | 544 | static const struct snd_kcontrol_new dac33_dapm_right_lom_control = |
551 | SOC_DAPM_ENUM("Route", dac33_right_lom_enum); | 545 | SOC_DAPM_ENUM("Route", dac33_right_lom_enum); |