[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180212181547.2415-1-ckeepax@opensource.cirrus.com>
Date: Mon, 12 Feb 2018 18:15:44 +0000
From: Charles Keepax <ckeepax@...nsource.cirrus.com>
To: <broonie@...nel.org>
CC: <david.rhodes@...rus.com>, <linux-kernel@...r.kernel.org>,
<patches@...nsource.cirrus.com>
Subject: [PATCH 1/4] regmap: Correct comparison in regmap_cached
The cache pointer points to the actual memory used by the cache, as the
comparison here is looking for the type of the cache it should check
against cache_type.
Fixes: 1ea975cf1ef5 ("regmap: Add a function to check if a regmap register is cached")
Signed-off-by: Charles Keepax <ckeepax@...nsource.cirrus.com>
---
drivers/base/regmap/regmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
index 453116fd4362e..c7b7c5fa73ab4 100644
--- a/drivers/base/regmap/regmap.c
+++ b/drivers/base/regmap/regmap.c
@@ -99,7 +99,7 @@ bool regmap_cached(struct regmap *map, unsigned int reg)
int ret;
unsigned int val;
- if (map->cache == REGCACHE_NONE)
+ if (map->cache_type == REGCACHE_NONE)
return false;
if (!map->cache_ops)
--
2.11.0
Powered by blists - more mailing lists