summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-01-21 13:11:53 +0100
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-02-22 14:57:03 +0100
commit462835e4a7f898662cc30064a33177af4823ef9d (patch)
tree0b9fec7de86ad6d9503d50efda445ce441ac582d /sound
parentmfd: Add __devinit and __devexit annotations in wm8994 (diff)
downloadlinux-462835e4a7f898662cc30064a33177af4823ef9d.tar.xz
linux-462835e4a7f898662cc30064a33177af4823ef9d.zip
mfd/ASoC: Convert WM8994 driver to use regmap patches
Early revisions of several of the WM8994 variants have register updates to improve performance. Move these over to using the regmap patch system instead of open coding them in the audio driver. Since the regmap init is done by the MFD the code is moved there. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/wm8994.c25
1 files changed, 1 insertions, 24 deletions
diff --git a/sound/soc/codecs/wm8994.c b/sound/soc/codecs/wm8994.c
index ec69a6c152fe..7c686abf8bd9 100644
--- a/sound/soc/codecs/wm8994.c
+++ b/sound/soc/codecs/wm8994.c
@@ -2099,26 +2099,9 @@ static int wm8994_set_bias_level(struct snd_soc_codec *codec,
case SND_SOC_BIAS_STANDBY:
if (codec->dapm.bias_level == SND_SOC_BIAS_OFF) {
switch (control->type) {
- case WM8994:
- if (wm8994->revision < 4) {
- /* Tweak DC servo and DSP
- * configuration for improved
- * performance. */
- snd_soc_write(codec, 0x102, 0x3);
- snd_soc_write(codec, 0x56, 0x3);
- snd_soc_write(codec, 0x817, 0);
- snd_soc_write(codec, 0x102, 0);
- }
- break;
-
case WM8958:
if (wm8994->revision == 0) {
/* Optimise performance for rev A */
- snd_soc_write(codec, 0x102, 0x3);
- snd_soc_write(codec, 0xcb, 0x81);
- snd_soc_write(codec, 0x817, 0);
- snd_soc_write(codec, 0x102, 0);
-
snd_soc_update_bits(codec,
WM8958_CHARGE_PUMP_2,
WM8958_CP_DISCH,
@@ -2126,13 +2109,7 @@ static int wm8994_set_bias_level(struct snd_soc_codec *codec,
}
break;
- case WM1811:
- if (wm8994->revision < 2) {
- snd_soc_write(codec, 0x102, 0x3);
- snd_soc_write(codec, 0x5d, 0x7e);
- snd_soc_write(codec, 0x5e, 0x0);
- snd_soc_write(codec, 0x102, 0x0);
- }
+ default:
break;
}