[alsa-devel] [PATCH 097/102] ASoC: wm8960: Use SOC_ENUM_SINGLE_CONST()

Takashi Iwai tiwai at suse.de
Tue Feb 18 12:51:43 CET 2014


... for improving readability and maintainability.

Signed-off-by: Takashi Iwai <tiwai at suse.de>
---
 sound/soc/codecs/wm8960.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/sound/soc/codecs/wm8960.c b/sound/soc/codecs/wm8960.c
index f156010e52bc..79cf2d6c459e 100644
--- a/sound/soc/codecs/wm8960.c
+++ b/sound/soc/codecs/wm8960.c
@@ -138,12 +138,12 @@ static const char *wm8960_alcfunc[] = {"Off", "Right", "Left", "Stereo"};
 static const char *wm8960_alcmode[] = {"ALC", "Limiter"};
 
 static const struct soc_enum wm8960_enum[] = {
-	SOC_ENUM_SINGLE(WM8960_DACCTL1, 5, 4, wm8960_polarity),
-	SOC_ENUM_SINGLE(WM8960_DACCTL2, 5, 4, wm8960_polarity),
-	SOC_ENUM_SINGLE(WM8960_3D, 6, 2, wm8960_3d_upper_cutoff),
-	SOC_ENUM_SINGLE(WM8960_3D, 5, 2, wm8960_3d_lower_cutoff),
-	SOC_ENUM_SINGLE(WM8960_ALC1, 7, 4, wm8960_alcfunc),
-	SOC_ENUM_SINGLE(WM8960_ALC3, 8, 2, wm8960_alcmode),
+	SOC_ENUM_SINGLE_CONST(WM8960_DACCTL1, 5, wm8960_polarity),
+	SOC_ENUM_SINGLE_CONST(WM8960_DACCTL2, 5, wm8960_polarity),
+	SOC_ENUM_SINGLE_CONST(WM8960_3D, 6, wm8960_3d_upper_cutoff),
+	SOC_ENUM_SINGLE_CONST(WM8960_3D, 5, wm8960_3d_lower_cutoff),
+	SOC_ENUM_SINGLE_CONST(WM8960_ALC1, 7, wm8960_alcfunc),
+	SOC_ENUM_SINGLE_CONST(WM8960_ALC3, 8, wm8960_alcmode),
 };
 
 static const int deemph_settings[] = { 0, 32000, 44100, 48000 };
-- 
1.8.5.2



More information about the Alsa-devel mailing list