Skip to contentSkip to conversation

ASoC: wm2000: Expose ANC gain adjustment

PATCH New Mark Brown 1 participant 1 message Jan 30, 2013

Subsystems (3)
lore
Share & tools
lore

Mark Brown

author
#0 lore raw

PATCH 1/1 ASoC: wm2000: Expose ANC gain adjustment

No TLV information since it's not actually a direct gain control.

---
 sound/soc/codecs/wm2000.c |    3 +++
 1 file changed, 3 insertions(+)
sound/soc/codecs/wm2000.c +3 -0
index 4d809ab..f2ac38b 100644
@@ -666,6 +666,7 @@ static int wm2000_speaker_put(struct snd_kcontrol *kcontrol,
 }
 
 static const struct snd_kcontrol_new wm2000_controls[] = {
+	SOC_SINGLE("ANC Volume", WM2000_REG_ANC_GAIN_CTRL, 0, 255, 0),
 	SOC_SINGLE_BOOL_EXT("WM2000 ANC Switch", 0,
 			    wm2000_anc_mode_get,
 			    wm2000_anc_mode_put),
@@ -778,6 +779,8 @@ static int wm2000_probe(struct snd_soc_codec *codec)
 {
 	struct wm2000_priv *wm2000 = dev_get_drvdata(codec->dev);
 
+	snd_soc_codec_set_cache_io(codec, 16, 8, SND_SOC_REGMAP);
+
 	/* This will trigger a transition to standby mode by default */
 	wm2000_anc_set_mode(wm2000);
 
Signature · 1 line
1.7.10.4