Commit 2cd148f1 authored by Mark Brown's avatar Mark Brown

regmap: Fix lock used for regcache_cache_only()

Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 38f69169
...@@ -273,9 +273,9 @@ EXPORT_SYMBOL_GPL(regcache_sync); ...@@ -273,9 +273,9 @@ EXPORT_SYMBOL_GPL(regcache_sync);
*/ */
void regcache_cache_only(struct regmap *map, bool enable) void regcache_cache_only(struct regmap *map, bool enable)
{ {
mutex_lock(&map->sync_lock); mutex_lock(&map->lock);
map->cache_only = enable; map->cache_only = enable;
mutex_unlock(&map->sync_lock); mutex_unlock(&map->lock);
} }
EXPORT_SYMBOL_GPL(regcache_cache_only); EXPORT_SYMBOL_GPL(regcache_cache_only);
......
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