Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 303460
b: refs/heads/master
c: fde0190
h: refs/heads/master
v: v3
  • Loading branch information
Peter Ujfalusi authored and Tony Lindgren committed May 9, 2012
1 parent 49ddd06 commit 829e5d5
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1afb82e4529f7e1876f6c2ceebc40ac284558eec
refs/heads/master: fde0190d698ee57f0396275ab7218f75526827a9
43 changes: 43 additions & 0 deletions trunk/arch/arm/mach-omap2/twl-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,7 @@ static struct regulator_init_data omap4_vdac_idata = {
.valid_ops_mask = REGULATOR_CHANGE_MODE
| REGULATOR_CHANGE_STATUS,
},
.supply_regulator = "V2V1",
};

static struct regulator_init_data omap4_vaux2_idata = {
Expand Down Expand Up @@ -356,6 +357,7 @@ static struct regulator_init_data omap4_vcxio_idata = {
},
.num_consumer_supplies = ARRAY_SIZE(omap4_vcxio_supply),
.consumer_supplies = omap4_vcxio_supply,
.supply_regulator = "V2V1",
};

static struct regulator_init_data omap4_vusb_idata = {
Expand Down Expand Up @@ -439,6 +441,41 @@ static struct twl_regulator_driver_data omap4_vdd3_drvdata = {
.set_voltage = twl_set_voltage,
};

static struct regulator_consumer_supply omap4_v1v8_supply[] = {
REGULATOR_SUPPLY("vio", "1-004b"),
};

static struct regulator_init_data omap4_v1v8_idata = {
.constraints = {
.min_uV = 1800000,
.max_uV = 1800000,
.valid_modes_mask = REGULATOR_MODE_NORMAL
| REGULATOR_MODE_STANDBY,
.valid_ops_mask = REGULATOR_CHANGE_MODE
| REGULATOR_CHANGE_STATUS,
.always_on = true,
},
.num_consumer_supplies = ARRAY_SIZE(omap4_v1v8_supply),
.consumer_supplies = omap4_v1v8_supply,
};

static struct regulator_consumer_supply omap4_v2v1_supply[] = {
REGULATOR_SUPPLY("v2v1", "1-004b"),
};

static struct regulator_init_data omap4_v2v1_idata = {
.constraints = {
.min_uV = 2100000,
.max_uV = 2100000,
.valid_modes_mask = REGULATOR_MODE_NORMAL
| REGULATOR_MODE_STANDBY,
.valid_ops_mask = REGULATOR_CHANGE_MODE
| REGULATOR_CHANGE_STATUS,
},
.num_consumer_supplies = ARRAY_SIZE(omap4_v2v1_supply),
.consumer_supplies = omap4_v2v1_supply,
};

void __init omap4_pmic_get_config(struct twl4030_platform_data *pmic_data,
u32 pdata_flags, u32 regulators_flags)
{
Expand Down Expand Up @@ -497,5 +534,11 @@ void __init omap4_pmic_get_config(struct twl4030_platform_data *pmic_data,
if (regulators_flags & TWL_COMMON_REGULATOR_CLK32KG &&
!pmic_data->clk32kg)
pmic_data->clk32kg = &omap4_clk32kg_idata;

if (regulators_flags & TWL_COMMON_REGULATOR_V1V8 && !pmic_data->v1v8)
pmic_data->v1v8 = &omap4_v1v8_idata;

if (regulators_flags & TWL_COMMON_REGULATOR_V2V1 && !pmic_data->v2v1)
pmic_data->v2v1 = &omap4_v2v1_idata;
}
#endif /* CONFIG_ARCH_OMAP4 */
2 changes: 2 additions & 0 deletions trunk/arch/arm/mach-omap2/twl-common.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
#define TWL_COMMON_REGULATOR_VCXIO (1 << 8)
#define TWL_COMMON_REGULATOR_VUSB (1 << 9)
#define TWL_COMMON_REGULATOR_CLK32KG (1 << 10)
#define TWL_COMMON_REGULATOR_V1V8 (1 << 11)
#define TWL_COMMON_REGULATOR_V2V1 (1 << 12)

/* TWL4030 LDO regulators */
#define TWL_COMMON_REGULATOR_VPLL1 (1 << 4)
Expand Down

0 comments on commit 829e5d5

Please sign in to comment.