]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sgtl5000: Fix the cache handling
authorFabio Estevam <fabio.estevam@freescale.com>
Mon, 26 May 2014 13:34:20 +0000 (10:34 -0300)
committerMark Brown <broonie@linaro.org>
Tue, 27 May 2014 11:22:15 +0000 (12:22 +0100)
commit21da88dd5c3f32eee16e53e320287b79246f7349
tree95fce255a4ae2edd577c9a63934c30fab7d8bdf3
parent92abf27d294b7aa4c83f8452987372d590aea466
ASoC: sgtl5000: Fix the cache handling

Since commit 2d9c7a269a05 (ASoC: sgtl5000: Convert to use regmap directly) a
kernel oops is observed after a suspend/resume sequence.

The kernel oops happens inside sgtl5000_restore_regs() as codec->reg_cache is no
longer a valid pointer.

Add the remaining register entries into sgtl5000_reg_defaults[] and remove
sgtl5000_restore_regs() completely, which allows suspend/resume to work fine and
make the code simpler.

Tested on a im53-qsb board.

Reported-by: Shawn Guo <shawn.guo@freescale.com>
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Tested-by: Shawn Guo <shawn.guo@freescale.com>
Signed-off-by: Mark Brown <broonie@linaro.org>
sound/soc/codecs/sgtl5000.c