Skip to content

Commit

Permalink
ASoC: wm8741: Use snd_soc_cache_sync to sync reg_cache with the hardware
Browse files Browse the repository at this point in the history
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Axel Lin authored and Mark Brown committed Oct 17, 2011
1 parent 3a34010 commit df3431b
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions sound/soc/codecs/wm8741.c
Original file line number Diff line number Diff line change
Expand Up @@ -404,15 +404,7 @@ static struct snd_soc_dai_driver wm8741_dai = {
#ifdef CONFIG_PM
static int wm8741_resume(struct snd_soc_codec *codec)
{
u16 *cache = codec->reg_cache;
int i;

/* RESTORE REG Cache */
for (i = 0; i < WM8741_REGISTER_COUNT; i++) {
if (cache[i] == wm8741_reg_defaults[i] || WM8741_RESET == i)
continue;
snd_soc_write(codec, i, cache[i]);
}
snd_soc_cache_sync(codec);
return 0;
}
#else
Expand Down

0 comments on commit df3431b

Please sign in to comment.