summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorBengt Jonsson <bengt.g.jonsson@stericsson.com>2011-10-31 17:33:55 +0100
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-05-22 10:59:19 +0200
commitd3be611d7c9f400ac738a0e1a0103237a1fdf2c7 (patch)
treed8e1f7c37efcb4b17daa02ff126cea25cb81814d /drivers
parent47c3ceb93a8cb8b2ba0dd7b940d7142f3844da18 (diff)
regulator: ab8500-ext: Add VextSupply1 regulator
Remove suspend-force settings of VextSupply1 and add VextSupply1 in the external regulator driver. ST-Ericsson Linux next: - ST-Ericsson ID: 374223 ST-Ericsson FOSS-OUT ID: Trivial Change-Id: I0a8b8c813159dcf44e24bc4a0bfd36beb954a459 Signed-off-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/37702
Diffstat (limited to 'drivers')
-rw-r--r--drivers/regulator/ab8500-debug.c9
-rw-r--r--drivers/regulator/ab8500-ext.c18
2 files changed, 22 insertions, 5 deletions
diff --git a/drivers/regulator/ab8500-debug.c b/drivers/regulator/ab8500-debug.c
index da182641b2c..50789258654 100644
--- a/drivers/regulator/ab8500-debug.c
+++ b/drivers/regulator/ab8500-debug.c
@@ -1526,12 +1526,11 @@ static struct ab8500_force_reg ab8500_force_reg[] = {
* ExtSupplyRegu (HSI: 0x2a on v2-v40?)
* OTP: 0x15, HSI: 0x28, suspend: 0x28/0x3f (value/mask)
* [3:2] VExtSupply2Regu[1:0] = 10 = Vext2 in HW control
- * [1:0] VExtSupply1Regu[1:0] = 00 = Vext1 off
*/
.name = "ExtSupplyRegu",
.bank = 0x04,
.addr = 0x08,
- .mask = 0x0f,
+ .mask = 0x0c,
.val = 0x08,
},
{
@@ -1736,15 +1735,15 @@ static int __devinit ab8500_regulator_debug_probe(struct platform_device *plf)
if ((abx500_get_chip_id(&pdev->dev) >= 0x30) && cpu_is_u8500v22()) {
/*
* find ExtSupplyRegu register (bank 0x04, addr 0x08)
- * and update value (Vext1 in low-power, Vext2 off).
+ * and update value (Vext2 off).
*/
for (i = 0; i < ARRAY_SIZE(ab8500_force_reg); i++) {
if (ab8500_force_reg[i].bank == 0x04 &&
ab8500_force_reg[i].addr == 0x08) {
- u8 val, val_mask = 0x0f;
+ u8 val, val_mask = 0x0c;
val = ab8500_force_reg[i].val;
- val = (val & ~val_mask) | (0x03 & val_mask);
+ val = (val & ~val_mask) | (0x00 & val_mask);
ab8500_force_reg[i].val = val;
}
}
diff --git a/drivers/regulator/ab8500-ext.c b/drivers/regulator/ab8500-ext.c
index 347b3b5752a..f6ce6623460 100644
--- a/drivers/regulator/ab8500-ext.c
+++ b/drivers/regulator/ab8500-ext.c
@@ -300,6 +300,24 @@ static struct regulator_ops ab8500_ext_regulator_ops = {
static struct ab8500_ext_regulator_info
ab8500_ext_regulator_info[AB8500_NUM_EXT_REGULATORS] = {
+ [AB8500_EXT_SUPPLY1] = {
+ .desc = {
+ .name = "VEXTSUPPLY1",
+ .ops = &ab8500_ext_regulator_ops,
+ .type = REGULATOR_VOLTAGE,
+ .id = AB8500_EXT_SUPPLY1,
+ .owner = THIS_MODULE,
+ .n_voltages = 1,
+ },
+ .fixed_uV = 1800000,
+ .update_bank = 0x04,
+ .update_reg = 0x08,
+ .update_mask = 0x03,
+ .update_val = 0x01,
+ .update_val_hp = 0x01,
+ .update_val_lp = 0x03,
+ .update_val_hw = 0x02,
+ },
[AB8500_EXT_SUPPLY3] = {
.desc = {
.name = "VEXTSUPPLY3",