[PATCH 4/4] ASoC: rt5682: do nothing in rt5682_suspend/resume in sdw mode
Pierre-Louis Bossart
pierre-louis.bossart at linux.intel.com
Thu Feb 4 21:17:39 CET 2021
From: Bard Liao <yung-chuan.liao at linux.intel.com>
regcache sync will be done in sdw device suspend/resume functions.
And we have different jack detection mechanism for SoundWire.
Signed-off-by: Bard Liao <yung-chuan.liao at linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart at linux.intel.com>
---
sound/soc/codecs/rt5682.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/sound/soc/codecs/rt5682.c b/sound/soc/codecs/rt5682.c
index 185906d6d4e0..b306ac4b9b2e 100644
--- a/sound/soc/codecs/rt5682.c
+++ b/sound/soc/codecs/rt5682.c
@@ -2910,6 +2910,9 @@ static int rt5682_suspend(struct snd_soc_component *component)
{
struct rt5682_priv *rt5682 = snd_soc_component_get_drvdata(component);
+ if (rt5682->is_sdw)
+ return 0;
+
regcache_cache_only(rt5682->regmap, true);
regcache_mark_dirty(rt5682->regmap);
return 0;
@@ -2919,6 +2922,9 @@ static int rt5682_resume(struct snd_soc_component *component)
{
struct rt5682_priv *rt5682 = snd_soc_component_get_drvdata(component);
+ if (rt5682->is_sdw)
+ return 0;
+
regcache_cache_only(rt5682->regmap, false);
regcache_sync(rt5682->regmap);
--
2.25.1
More information about the Alsa-devel
mailing list