diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-02-23 22:05:59 +0000 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-02-23 22:07:19 +0000 |
commit | 6ff7373809a9b4eb644d83e2e299da297e1cbffa (patch) | |
tree | b8cb568ef36f900a356327e2bb5ea19cb77719ec /drivers/base/regmap | |
parent | c3ec23288a92e20e0aff84a4cb6fbc7cc9bcf567 (diff) | |
download | linux-6ff7373809a9b4eb644d83e2e299da297e1cbffa.tar.bz2 |
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/regmap')
-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 */ |