From 3bf6bf9be51a0195c6b1604454fdd28ed1cc1770 Mon Sep 17 00:00:00 2001 From: Laxman Dewangan Date: Wed, 9 May 2012 18:40:54 +0530 Subject: [PATCH] mfd: Cache tps65910 register when we need it During regmap initialization, we do not provide the default value and hence in place of caching register during regmap_init(), cache it when actually we need it i.e. after reading of that register. Signed-off-by: Laxman Dewangan Reviewed-by: Mark Brown Signed-off-by: Samuel Ortiz --- drivers/mfd/tps65910.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/mfd/tps65910.c b/drivers/mfd/tps65910.c index a00c09ea0793..01570a789cf1 100644 --- a/drivers/mfd/tps65910.c +++ b/drivers/mfd/tps65910.c @@ -62,8 +62,7 @@ static const struct regmap_config tps65910_regmap_config = { .reg_bits = 8, .val_bits = 8, .volatile_reg = is_volatile_reg, - .max_register = TPS65910_MAX_REGISTER, - .num_reg_defaults_raw = TPS65910_MAX_REGISTER, + .max_register = TPS65910_MAX_REGISTER - 1, .cache_type = REGCACHE_RBTREE, }; -- 2.39.5