aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/base/regmap/regmap.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2013-04-09 13:03:25 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2013-04-09 13:03:25 -0400
commit51a246aa5c0a14b3d34a5c6d3c9e271c784b127f (patch)
treeda3de8af869c4262a0d983c4c20e5a3d9d31b1f5 /drivers/base/regmap/regmap.c
parent31880c37c11e28cb81c70757e38392b42e695dc6 (diff)
regmap: Back out work buffer fix
This reverts commit bc8ce4 (regmap: don't corrupt work buffer in _regmap_raw_write()) since it turns out that it can cause issues when taken in isolation from the other changes in -next that lead to its discovery. On the basis that nobody noticed the problems for quite some time without that subsequent work let's drop it from v3.9. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/base/regmap/regmap.c')
-rw-r--r--drivers/base/regmap/regmap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
index d34adef1e63e..58cfb3232428 100644
--- a/drivers/base/regmap/regmap.c
+++ b/drivers/base/regmap/regmap.c
@@ -943,7 +943,8 @@ static int _regmap_raw_write(struct regmap *map, unsigned int reg,
943 unsigned int ival; 943 unsigned int ival;
944 int val_bytes = map->format.val_bytes; 944 int val_bytes = map->format.val_bytes;
945 for (i = 0; i < val_len / val_bytes; i++) { 945 for (i = 0; i < val_len / val_bytes; i++) {
946 ival = map->format.parse_val(val + (i * val_bytes)); 946 memcpy(map->work_buf, val + (i * val_bytes), val_bytes);
947 ival = map->format.parse_val(map->work_buf);
947 ret = regcache_write(map, reg + (i * map->reg_stride), 948 ret = regcache_write(map, reg + (i * map->reg_stride),
948 ival); 949 ival);
949 if (ret) { 950 if (ret) {