diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-02-23 23:05:59 +0100 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-02-23 23:07:19 +0100 |
commit | 6ff7373809a9b4eb644d83e2e299da297e1cbffa (patch) | |
tree | b8cb568ef36f900a356327e2bb5ea19cb77719ec /drivers/base | |
parent | regmap: Remove default cache sync implementation (diff) | |
download | linux-6ff7373809a9b4eb644d83e2e299da297e1cbffa.tar.xz linux-6ff7373809a9b4eb644d83e2e299da297e1cbffa.zip |
regmap: Mark the cache as clean after a successful sync
Previously the cache would never be marked clean, meaning syncs would
never be suppressed which isn't the end of the world but could be
inefficient.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/regmap/regcache.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/base/regmap/regcache.c b/drivers/base/regmap/regcache.c index 4d43ed363481..46c42d3a4655 100644 --- a/drivers/base/regmap/regcache.c +++ b/drivers/base/regmap/regcache.c @@ -285,6 +285,9 @@ int regcache_sync(struct regmap *map) ret = map->cache_ops->sync(map); + if (ret == 0) + map->cache_dirty = false; + out: trace_regcache_sync(map->dev, name, "stop"); /* Restore the bypass state */ |