浏览代码

regmap: Fix lock used for regcache_cache_only()

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown 14 年之前
父节点
当前提交
2cd148f159
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      drivers/base/regmap/regcache.c

+ 2 - 2
drivers/base/regmap/regcache.c

@@ -273,9 +273,9 @@ EXPORT_SYMBOL_GPL(regcache_sync);
  */
 void regcache_cache_only(struct regmap *map, bool enable)
 {
-	mutex_lock(&map->sync_lock);
+	mutex_lock(&map->lock);
 	map->cache_only = enable;
-	mutex_unlock(&map->sync_lock);
+	mutex_unlock(&map->lock);
 }
 EXPORT_SYMBOL_GPL(regcache_cache_only);