[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1331118545-26514-1-git-send-email-ldewangan@nvidia.com>
Date: Wed, 7 Mar 2012 16:39:05 +0530
From: Laxman Dewangan <ldewangan@...dia.com>
To: lrg@...com, broonie@...nsource.wolfsonmicro.com
Cc: linux-kernel@...r.kernel.org, linux-tegra@...r.kernel.org,
ldewangan@...dia.com
Subject: [PATCH V1] 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@...dia.com>
---
drivers/regulator/tps65910-regulator.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/regulator/tps65910-regulator.c b/drivers/regulator/tps65910-regulator.c
index 15b5f1e..8de2835 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);
}
--
1.7.1.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists