mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/2] regmap: cache: Step by stride in default sync.
@ 2014-03-18 20:45 Dylan Reid
  2014-03-18 20:45 ` [PATCH 2/2] regmap: cache: Don't attempt to sync non-writeable registers Dylan Reid
  2014-03-19 10:39 ` [PATCH 1/2] regmap: cache: Step by stride in default sync Mark Brown
  0 siblings, 2 replies; 4+ messages in thread
From: Dylan Reid @ 2014-03-18 20:45 UTC (permalink / raw)
  To: linux-kernel; +Cc: broonie, Dylan Reid

The default sync operation was still assuming a stride of one, fix it
to respect the reg_stride set in the map.

Signed-off-by: Dylan Reid <dgreid@chromium.org>
---
 drivers/base/regmap/regcache.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/base/regmap/regcache.c b/drivers/base/regmap/regcache.c
index c6b1ac1..44af125 100644
--- a/drivers/base/regmap/regcache.c
+++ b/drivers/base/regmap/regcache.c
@@ -249,7 +249,7 @@ static int regcache_default_sync(struct regmap *map, unsigned int min,
 {
 	unsigned int reg;
 
-	for (reg = min; reg <= max; reg++) {
+	for (reg = min; reg <= max; reg += map->reg_stride) {
 		unsigned int val;
 		int ret;
 
-- 
1.8.1.3.605.g02339dd


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-03-19 10:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-18 20:45 [PATCH 1/2] regmap: cache: Step by stride in default sync Dylan Reid
2014-03-18 20:45 ` [PATCH 2/2] regmap: cache: Don't attempt to sync non-writeable registers Dylan Reid
2014-03-19 10:39   ` Mark Brown
2014-03-19 10:39 ` [PATCH 1/2] regmap: cache: Step by stride in default sync Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®