ASoC: multi-component: TWL4030: Restore registers on removal
authorPeter Ujfalusi <peter.ujfalusi@nokia.com>
Thu, 12 Aug 2010 06:29:52 +0000 (09:29 +0300)
committerLiam Girdwood <lrg@slimlogic.co.uk>
Thu, 12 Aug 2010 13:04:35 +0000 (14:04 +0100)
Add back the register restore call, when the codec driver is
removed.
This does not affect normal operation, but it is usefull when
debugging audio through the twl4030 class codecs.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
sound/soc/codecs/twl4030.c

index 898430f44f9def4551c1f0a05b3258f37728d576..c7ee1a4c9d99f0643318333bf48831a139ef87fc 100644 (file)
@@ -2258,6 +2258,8 @@ static int twl4030_soc_probe(struct snd_soc_codec *codec)
 
 static int twl4030_soc_remove(struct snd_soc_codec *codec)
 {
+       /* Reset registers to their chip default before leaving */
+       twl4030_reset_registers(codec);
        twl4030_set_bias_level(codec, SND_SOC_BIAS_OFF);
        return 0;
 }