imx6: update 3.10 patches
[openwrt/svn-archive/archive.git] / target / linux / imx6 / patches-3.10 / 0028-regulator-pfuze100-Fix-off-by-one-for-max_register-s.patch
1 From: Axel Lin <axel.lin@ingics.com>
2 Subject: [PATCH] regulator: pfuze100: Fix off-by-one for max_register setting
3
4 max_register should be register count - 1.
5
6 Signed-off-by: Axel Lin <axel.lin@ingics.com>
7 Reviewed-by: Robin Gong <b38343@freescale.com>
8 Signed-off-by: Mark Brown <broonie@linaro.org>
9 ---
10 drivers/regulator/pfuze100-regulator.c | 2 +-
11 1 file changed, 1 insertion(+), 1 deletion(-)
12
13 --- a/drivers/regulator/pfuze100-regulator.c
14 +++ b/drivers/regulator/pfuze100-regulator.c
15 @@ -332,7 +332,7 @@ static int pfuze_identify(struct pfuze_c
16 static const struct regmap_config pfuze_regmap_config = {
17 .reg_bits = 8,
18 .val_bits = 8,
19 - .max_register = PFUZE_NUMREGS,
20 + .max_register = PFUZE_NUMREGS - 1,
21 .cache_type = REGCACHE_RBTREE,
22 };
23