提交 e42c5a9a 编写于 作者: M Mark Brown

regmap: Allow rbtree to cache zero default values

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: NMark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: NDimitris Papastamos <dp@opensource.wolfsonmicro.com>
上级 04e016ad
无相关合并请求
......@@ -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)) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
反馈
建议
客服 返回
顶部