aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2014-09-02 16:20:34 -0400
committerMark Brown <broonie@kernel.org>2014-09-03 14:26:26 -0400
commite02c716d2ec065fd58c2fc8100fd5f359ab61e7e (patch)
tree71e88615824b41d54074ac578fc02639f15ec609
parenta7edeba4cbbd0f3d22d6d54da7c507bda29b2658 (diff)
ASoC: wm8995: Remove unnecessary suspend/resume bias level changes
The ASoC core will only call the suspend/resume callbacks when the device's DAPM context is idle. Since this driver sets idle_bias_off to true this means that the device is already in SND_SOC_BIAS_OFF when the suspend callback is called, so there is no need to manually set this state again. There is also no need to go to SND_SOC_BIAS_STANDBY in the resume callback since the core will go right back to SND_SOC_BIAS_OFF. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/codecs/wm8995.c19
1 files changed, 0 insertions, 19 deletions
diff --git a/sound/soc/codecs/wm8995.c b/sound/soc/codecs/wm8995.c
index cae4ac5a5730..1288edeb8c7d 100644
--- a/sound/soc/codecs/wm8995.c
+++ b/sound/soc/codecs/wm8995.c
@@ -1998,23 +1998,6 @@ static int wm8995_set_bias_level(struct snd_soc_codec *codec,
1998 return 0; 1998 return 0;
1999} 1999}
2000 2000
2001#ifdef CONFIG_PM
2002static int wm8995_suspend(struct snd_soc_codec *codec)
2003{
2004 wm8995_set_bias_level(codec, SND_SOC_BIAS_OFF);
2005 return 0;
2006}
2007
2008static int wm8995_resume(struct snd_soc_codec *codec)
2009{
2010 wm8995_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
2011 return 0;
2012}
2013#else
2014#define wm8995_suspend NULL
2015#define wm8995_resume NULL
2016#endif
2017
2018static int wm8995_remove(struct snd_soc_codec *codec) 2001static int wm8995_remove(struct snd_soc_codec *codec)
2019{ 2002{
2020 struct wm8995_priv *wm8995; 2003 struct wm8995_priv *wm8995;
@@ -2220,8 +2203,6 @@ static struct snd_soc_dai_driver wm8995_dai[] = {
2220static struct snd_soc_codec_driver soc_codec_dev_wm8995 = { 2203static struct snd_soc_codec_driver soc_codec_dev_wm8995 = {
2221 .probe = wm8995_probe, 2204 .probe = wm8995_probe,
2222 .remove = wm8995_remove, 2205 .remove = wm8995_remove,
2223 .suspend = wm8995_suspend,
2224 .resume = wm8995_resume,
2225 .set_bias_level = wm8995_set_bias_level, 2206 .set_bias_level = wm8995_set_bias_level,
2226 .idle_bias_off = true, 2207 .idle_bias_off = true,
2227}; 2208};