aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/sound/soc/codecs/rt5682-sdw.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2023-08-17 16:03:20 +0200
committerMark Brown <broonie@kernel.org>2023-08-17 15:10:13 +0100
commited11701751d43fb2318c625e65e0507b5234f8a5 (patch)
tree4770e3209f0231b41b25577c476a3baabc8dc775 /sound/soc/codecs/rt5682-sdw.c
parentASoC: rt5668: Convert to use GPIO descriptors (diff)
downloadwireguard-linux-ed11701751d43fb2318c625e65e0507b5234f8a5.tar.xz
wireguard-linux-ed11701751d43fb2318c625e65e0507b5234f8a5.zip
ASoC: rt5682: Convert to use GPIO descriptors
Convert the RT5682 to use GPIO descriptors and drop the legacy GPIO headers. We remove the global GPIO number from the platform data, but it is still possible to create board files using GPIO descriptor tables, if desired. Make sure to make sure SDW devices can associate with an LDO1 EN descriptor too, if they so desire by putting the lookup into the common code. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20230817-descriptors-asoc-rt-v2-4-02fa2ca3e5b0@linaro.org Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/rt5682-sdw.c')
-rw-r--r--sound/soc/codecs/rt5682-sdw.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/soc/codecs/rt5682-sdw.c b/sound/soc/codecs/rt5682-sdw.c
index 65e9c6dc1a54..e67c2e19cb1a 100644
--- a/sound/soc/codecs/rt5682-sdw.c
+++ b/sound/soc/codecs/rt5682-sdw.c
@@ -320,6 +320,11 @@ static int rt5682_sdw_init(struct device *dev, struct regmap *regmap,
return ret;
}
+
+ ret = rt5682_get_ldo1(rt5682, dev);
+ if (ret)
+ return ret;
+
regcache_cache_only(rt5682->sdw_regmap, true);
regcache_cache_only(rt5682->regmap, true);