summaryrefslogtreecommitdiff
path: root/drivers/regulator
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2012-03-07 16:39:05 +0530
committerRohan Somvanshi <rsomvanshi@nvidia.com>2012-03-09 06:05:29 -0800
commit103e9ab9ad42da8023f0199b2207b39c729ea9df (patch)
treec2fc9a8cee11fd670a972e52f70cb9683da34532 /drivers/regulator
parent651aef2849ce18a0e005492c400d7200e92bbc73 (diff)
regulator: tps65910: Configure correct value for VDDCTRL vout reg
As per datasheet, the voltage output is defined as from SEL[6:0] = 3 to 64 (dec) Vout= (SEL[6:0] × 12.5 mV + 562.5 mV) The list_voltage returns the vout as 600mV + selector * 12.5mV and so equivalent VSEL is selector + 3. Adding 3 on selector when configuring VSEL register for VDDCTRL output. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> cherry picked from mainline commit c4632aed3e5b134c55b54af19db49662959384c1 Change-Id: Ifc514a87803191cf796ffc0d75d979476e712dde Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/88830
Diffstat (limited to 'drivers/regulator')
-rw-r--r--drivers/regulator/tps65910-regulator.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/tps65910-regulator.c b/drivers/regulator/tps65910-regulator.c
index 8d8931d544c5..5ee214c40101 100644
--- a/drivers/regulator/tps65910-regulator.c
+++ b/drivers/regulator/tps65910-regulator.c
@@ -715,7 +715,7 @@ static int tps65910_set_voltage_dcdc(struct regulator_dev *dev,
tps65910_reg_write(pmic, TPS65910_VDD2_OP, vsel);
break;
case TPS65911_REG_VDDCTRL:
- vsel = selector;
+ vsel = selector + 3;
tps65910_reg_write(pmic, TPS65911_VDDCTRL_OP, vsel);
}