diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-03-23 21:49:37 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-03-23 21:49:37 +0100 |
commit | cd0e075784f4bce97b4ed47d4b354f045e895546 (patch) | |
tree | 2354d4c2f5185c59dc21c537841b55c694cc53ec /drivers/base/regmap/regcache.c | |
parent | usb: phy: msm: Remove dead code (diff) | |
parent | Linux 4.0-rc5 (diff) | |
download | linux-cd0e075784f4bce97b4ed47d4b354f045e895546.tar.xz linux-cd0e075784f4bce97b4ed47d4b354f045e895546.zip |
Merge 4.0-rc5 into usb-next
We want the USB fixes in here as well to resolve merge conflicts.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base/regmap/regcache.c')
-rw-r--r-- | drivers/base/regmap/regcache.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/base/regmap/regcache.c b/drivers/base/regmap/regcache.c index f373c35f9e1d..da84f544c544 100644 --- a/drivers/base/regmap/regcache.c +++ b/drivers/base/regmap/regcache.c @@ -608,7 +608,8 @@ static int regcache_sync_block_single(struct regmap *map, void *block, for (i = start; i < end; i++) { regtmp = block_base + (i * map->reg_stride); - if (!regcache_reg_present(cache_present, i)) + if (!regcache_reg_present(cache_present, i) || + !regmap_writeable(map, regtmp)) continue; val = regcache_get_val(map, block, i); @@ -677,7 +678,8 @@ static int regcache_sync_block_raw(struct regmap *map, void *block, for (i = start; i < end; i++) { regtmp = block_base + (i * map->reg_stride); - if (!regcache_reg_present(cache_present, i)) { + if (!regcache_reg_present(cache_present, i) || + !regmap_writeable(map, regtmp)) { ret = regcache_sync_block_raw_flush(map, &data, base, regtmp); if (ret != 0) |