Commit 87a4bb11 authored by Nicolin Chen's avatar Nicolin Chen Committed by Mark Brown

ASoC: cs53l30: Check return value of regcache_sync()

Regcache_sync() might fail. So this patch adds a return value Check for it.
Signed-off-by: default avatarNicolin Chen <nicoleotsuka@gmail.com>
Acked-by: default avatarPaul Handrigan <Paul.Handrigan@cirrus.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent b97c4446
......@@ -1055,7 +1055,11 @@ static int cs53l30_runtime_resume(struct device *dev)
gpiod_set_value_cansleep(cs53l30->reset_gpio, 1);
regcache_cache_only(cs53l30->regmap, false);
regcache_sync(cs53l30->regmap);
ret = regcache_sync(cs53l30->regmap);
if (ret) {
dev_err(dev, "failed to synchronize regcache: %d\n", ret);
return ret;
}
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment