aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc')
-rw-r--r--sound/soc/codecs/adav80x.c23
1 files changed, 2 insertions, 21 deletions
diff --git a/sound/soc/codecs/adav80x.c b/sound/soc/codecs/adav80x.c
index c43b93fdf0df..ce3cdca9fc62 100644
--- a/sound/soc/codecs/adav80x.c
+++ b/sound/soc/codecs/adav80x.c
@@ -812,42 +812,23 @@ static int adav80x_probe(struct snd_soc_codec *codec)
812 /* Disable DAC zero flag */ 812 /* Disable DAC zero flag */
813 regmap_write(adav80x->regmap, ADAV80X_DAC_CTRL3, 0x6); 813 regmap_write(adav80x->regmap, ADAV80X_DAC_CTRL3, 0x6);
814 814
815 return adav80x_set_bias_level(codec, SND_SOC_BIAS_STANDBY); 815 return 0;
816}
817
818static int adav80x_suspend(struct snd_soc_codec *codec)
819{
820 struct adav80x *adav80x = snd_soc_codec_get_drvdata(codec);
821 int ret;
822
823 ret = adav80x_set_bias_level(codec, SND_SOC_BIAS_OFF);
824 regcache_cache_only(adav80x->regmap, true);
825
826 return ret;
827} 816}
828 817
829static int adav80x_resume(struct snd_soc_codec *codec) 818static int adav80x_resume(struct snd_soc_codec *codec)
830{ 819{
831 struct adav80x *adav80x = snd_soc_codec_get_drvdata(codec); 820 struct adav80x *adav80x = snd_soc_codec_get_drvdata(codec);
832 821
833 regcache_cache_only(adav80x->regmap, false);
834 adav80x_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
835 regcache_sync(adav80x->regmap); 822 regcache_sync(adav80x->regmap);
836 823
837 return 0; 824 return 0;
838} 825}
839 826
840static int adav80x_remove(struct snd_soc_codec *codec)
841{
842 return adav80x_set_bias_level(codec, SND_SOC_BIAS_OFF);
843}
844
845static struct snd_soc_codec_driver adav80x_codec_driver = { 827static struct snd_soc_codec_driver adav80x_codec_driver = {
846 .probe = adav80x_probe, 828 .probe = adav80x_probe,
847 .remove = adav80x_remove,
848 .suspend = adav80x_suspend,
849 .resume = adav80x_resume, 829 .resume = adav80x_resume,
850 .set_bias_level = adav80x_set_bias_level, 830 .set_bias_level = adav80x_set_bias_level,
831 .suspend_bias_off = true,
851 832
852 .set_pll = adav80x_set_pll, 833 .set_pll = adav80x_set_pll,
853 .set_sysclk = adav80x_set_sysclk, 834 .set_sysclk = adav80x_set_sysclk,