regulator: replace ADTV1 register by ADTV2 in da903x

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linux Kernel Mailing List
Date: Wednesday, September 23, 2009 - 11:00 am

Gitweb:     http://git.kernel.org/linus/e88267e1646037fa2c155515c78bd01a5c81f058
Commit:     e88267e1646037fa2c155515c78bd01a5c81f058
Parent:     fc4f42e7fb021340c14dfd726313be6cfdeab19e
Author:     Haojian Zhuang <haojian.zhuang@marvell.com>
AuthorDate: Thu Jul 9 17:52:30 2009 +0800
Committer:  Liam Girdwood <lrg@slimlogic.co.uk>
CommitDate: Tue Sep 22 13:32:37 2009 +0100

    regulator: replace ADTV1 register by ADTV2 in da903x
    
    In PXA3xx SoC family, V_CORE power doamin is supplied by BUCK1 that is
    controller by ADTV1 or ADTV2 register.
    
    By default, v1 and v2 has the same copy. If v1 or v2 is updated, the last
    value that is written to either register takes effect. It means that v1
    and v2 has different copy. And the actual voltage output is determinated
    by last update on either register.
    
    DA9034/35 is binded with PXA3xx SoC family. While SoC is scaling OP or
    entering/exiting lower power mode, SoC needs to change voltage of V_CORE
    power doamin. In order to be efficient, POWER I2C (hardcode) mode could
    be enabled in SoC. In this mode, SoC will control v2 register directly.
    
    In original DA903x driver, software will only read regulator data from v1
    register. But SoC controls v2 register directly. It results that v1 and v2
    isn't synchronized. Wrong data will be read from v1 register. So access v2
    register in da903x driver instead.
    
    Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
    Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
    Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
---
 drivers/regulator/da903x.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/regulator/da903x.c b/drivers/regulator/da903x.c
index 49081b4..d8d251f 100644
--- a/drivers/regulator/da903x.c
+++ b/drivers/regulator/da903x.c
@@ -469,9 +469,9 @@ static struct da903x_regulator_info da903x_regulator_info[] = {
 	DA9030_LDO(13, 2100, 2100, 0, INVAL, 0, 0, RCTL11, 3), /* fixed @2.1V */
 
 	/* DA9034 */
-	DA9034_DVC(BUCK1, 725, 1500, 25, ADTV1, 5, VCC1, 0, OVER1, 0),
-	DA9034_DVC(BUCK2, 725, 1500, 25, CDTV1, 5, VCC1, 2, OVER1, 1),
-	DA9034_DVC(LDO2,  725, 1500, 25, SDTV1, 5, VCC1, 4, OVER1, 2),
+	DA9034_DVC(BUCK1, 725, 1500, 25, ADTV2, 5, VCC1, 0, OVER1, 0),
+	DA9034_DVC(BUCK2, 725, 1500, 25, CDTV2, 5, VCC1, 2, OVER1, 1),
+	DA9034_DVC(LDO2,  725, 1500, 25, SDTV2, 5, VCC1, 4, OVER1, 2),
 	DA9034_DVC(LDO1, 1700, 2075, 25, MDTV1, 4, VCC1, 6, OVER3, 4),
 
 	DA9034_LDO( 3, 1800, 3300, 100,  LDO643, 0, 4, OVER3, 5),
--
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
regulator: replace ADTV1 register by ADTV2 in da903x, Linux Kernel Mailing ..., (Wed Sep 23, 11:00 am)