summaryrefslogtreecommitdiff
path: root/drivers/base/regmap/regmap.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-05-01 02:26:32 +0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-05-01 02:30:15 +0400
commit7a6476143270d947924f5bbbc124accb0e558bf4 (patch)
tree252e0f561b881960bab761081c6548eef300f329 /drivers/base/regmap/regmap.c
parent2e33caf16f7a1903d226ef7f9f5ec6a234fee18e (diff)
downloadlinux-7a6476143270d947924f5bbbc124accb0e558bf4.tar.xz
regmap: Devices using format_write don't support bulk operations
Set the use_single_rw flag for devices that use format_write() since format_write() doesn't support any form of block operation. 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, 3 insertions, 0 deletions
diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
index 0a05a706e141..fcd69ff695d5 100644
--- a/drivers/base/regmap/regmap.c
+++ b/drivers/base/regmap/regmap.c
@@ -341,6 +341,9 @@ struct regmap *regmap_init(struct device *dev,
break;
}
+ if (map->format.format_write)
+ map->use_single_rw = true;
+
if (!map->format.format_write &&
!(map->format.format_reg && map->format.format_val))
goto err_map;