* [PATCH] regmap: Allow rbtree to cache zero default values
@ 2011-10-09 13:30 Mark Brown
0 siblings, 0 replies; only message in thread
From: Mark Brown @ 2011-10-09 13:30 UTC (permalink / raw)
To: dp; +Cc: linux-kernel, patches, Mark Brown
Ensure that when we start up in cache only mode we can store defaults of
zero, otherwise if the hardware is unavailable we won't be able to read.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
---
drivers/base/regmap/regcache-rbtree.c | 3 ---
1 files changed, 0 insertions(+), 3 deletions(-)
diff --git a/drivers/base/regmap/regcache-rbtree.c b/drivers/base/regmap/regcache-rbtree.c
index e04e36e..e314984 100644
--- a/drivers/base/regmap/regcache-rbtree.c
+++ b/drivers/base/regmap/regcache-rbtree.c
@@ -252,9 +252,6 @@ static int regcache_rbtree_write(struct regmap *map, unsigned int reg,
regcache_rbtree_set_register(rbnode, reg_tmp, value,
map->cache_word_size);
} else {
- /* bail out early, no need to create the rbnode yet */
- if (!value)
- return 0;
/* look for an adjacent register to the one we are about to add */
for (node = rb_first(&rbtree_ctx->root); node;
node = rb_next(node)) {
--
1.7.6.3
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-10-09 13:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-09 13:30 [PATCH] regmap: Allow rbtree to cache zero default values 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®