summaryrefslogtreecommitdiffstats
path: root/sound/soc
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-12-29 20:13:37 +0100
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-01-20 14:58:22 +0100
commite055cd67fda76dd8efdcdd4038f5adfe0f8e85a0 (patch)
tree181eeb9dcc49fbda97c5d042068786d6b4e5a1a4 /sound/soc
parentASoC: Remove wm8974 private data (diff)
downloadlinux-e055cd67fda76dd8efdcdd4038f5adfe0f8e85a0.tar.xz
linux-e055cd67fda76dd8efdcdd4038f5adfe0f8e85a0.zip
ASoC: Use standard cache sync for wm8804
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc')
-rw-r--r--sound/soc/codecs/wm8804.c20
1 files changed, 1 insertions, 19 deletions
diff --git a/sound/soc/codecs/wm8804.c b/sound/soc/codecs/wm8804.c
index d54a3ca5e19e..4d79cefe85db 100644
--- a/sound/soc/codecs/wm8804.c
+++ b/sound/soc/codecs/wm8804.c
@@ -482,24 +482,6 @@ static int wm8804_set_clkdiv(struct snd_soc_dai *dai,
return 0;
}
-static void wm8804_sync_cache(struct snd_soc_codec *codec)
-{
- short i;
- u8 *cache;
-
- if (!codec->cache_sync)
- return;
-
- codec->cache_only = 0;
- cache = codec->reg_cache;
- for (i = 0; i < codec->driver->reg_cache_size; i++) {
- if (i == WM8804_RST_DEVID1 || cache[i] == wm8804_reg_defs[i])
- continue;
- snd_soc_write(codec, i, cache[i]);
- }
- codec->cache_sync = 0;
-}
-
static int wm8804_set_bias_level(struct snd_soc_codec *codec,
enum snd_soc_bias_level level)
{
@@ -524,7 +506,7 @@ static int wm8804_set_bias_level(struct snd_soc_codec *codec,
ret);
return ret;
}
- wm8804_sync_cache(codec);
+ snd_soc_cache_sync(codec);
}
/* power down the OSC and the PLL */
snd_soc_update_bits(codec, WM8804_PWRDN, 0x9, 0x9);