summaryrefslogtreecommitdiff
path: root/arch/arm/mach-tegra/board-ventana-power.c
diff options
context:
space:
mode:
authorXin Xie <xxie@nvidia.com>2011-03-15 12:05:25 -0700
committerDan Willemsen <dwillemsen@nvidia.com>2011-11-30 21:46:14 -0800
commit89e5b67c36f5cdbd0f5b102cf901a40e4f499612 (patch)
treefd45747b297c554ccbbba11ddebe189599bbf314 /arch/arm/mach-tegra/board-ventana-power.c
parentb0bfd5e800688088d98702609d20d5f4ac6beafa (diff)
ARM: tegra: ventana: use PWM-only mode on the SM1
Original-Change-Id: I77b3df9125208e687af02d321c1e3ff9b5c041ca Reviewed-on: http://git-master/r/23057 Reviewed-by: Xin Xie <xxie@nvidia.com> Tested-by: Xin Xie <xxie@nvidia.com> Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Rebase-Id: Rc47774650bc007e8878110502a1c84375eae2925
Diffstat (limited to 'arch/arm/mach-tegra/board-ventana-power.c')
-rw-r--r--arch/arm/mach-tegra/board-ventana-power.c37
1 files changed, 23 insertions, 14 deletions
diff --git a/arch/arm/mach-tegra/board-ventana-power.c b/arch/arm/mach-tegra/board-ventana-power.c
index d496b86117d9..daf89b8c8d8d 100644
--- a/arch/arm/mach-tegra/board-ventana-power.c
+++ b/arch/arm/mach-tegra/board-ventana-power.c
@@ -107,7 +107,15 @@ static struct regulator_consumer_supply tps658621_ldo9_supply[] = {
REGULATOR_SUPPLY("avdd_amp", NULL),
};
-#define REGULATOR_INIT(_id, _minmv, _maxmv, on) \
+/*
+ * Current TPS6586x is known for having a voltage glitch if current load changes
+ * from low to high in auto PWM/PFM mode for CPU's Vdd line.
+ */
+static struct tps6586x_settings sm1_config = {
+ .sm_pwm_mode = PWM_ONLY,
+};
+
+#define REGULATOR_INIT(_id, _minmv, _maxmv, on, config) \
{ \
.constraints = { \
.min_uV = (_minmv)*1000, \
@@ -121,24 +129,25 @@ static struct regulator_consumer_supply tps658621_ldo9_supply[] = {
}, \
.num_consumer_supplies = ARRAY_SIZE(tps658621_##_id##_supply),\
.consumer_supplies = tps658621_##_id##_supply, \
+ .driver_data = config, \
}
#define ON 1
#define OFF 0
-static struct regulator_init_data sm0_data = REGULATOR_INIT(sm0, 725, 1500, ON);
-static struct regulator_init_data sm1_data = REGULATOR_INIT(sm1, 725, 1500, ON);
-static struct regulator_init_data sm2_data = REGULATOR_INIT(sm2, 3000, 4550, ON);
-static struct regulator_init_data ldo0_data = REGULATOR_INIT(ldo0, 1250, 3300, OFF);
-static struct regulator_init_data ldo1_data = REGULATOR_INIT(ldo1, 725, 1500, ON);
-static struct regulator_init_data ldo2_data = REGULATOR_INIT(ldo2, 725, 1500, OFF);
-static struct regulator_init_data ldo3_data = REGULATOR_INIT(ldo3, 1250, 3300, OFF);
-static struct regulator_init_data ldo4_data = REGULATOR_INIT(ldo4, 1700, 2475, OFF);
-static struct regulator_init_data ldo5_data = REGULATOR_INIT(ldo5, 1250, 3300, ON);
-static struct regulator_init_data ldo6_data = REGULATOR_INIT(ldo6, 1250, 1800, OFF);
-static struct regulator_init_data ldo7_data = REGULATOR_INIT(ldo7, 1250, 3300, OFF);
-static struct regulator_init_data ldo8_data = REGULATOR_INIT(ldo8, 1250, 3300, OFF);
-static struct regulator_init_data ldo9_data = REGULATOR_INIT(ldo9, 1250, 3300, OFF);
+static struct regulator_init_data sm0_data = REGULATOR_INIT(sm0, 725, 1500, ON, NULL);
+static struct regulator_init_data sm1_data = REGULATOR_INIT(sm1, 725, 1500, ON, &sm1_config);
+static struct regulator_init_data sm2_data = REGULATOR_INIT(sm2, 3000, 4550, ON, NULL);
+static struct regulator_init_data ldo0_data = REGULATOR_INIT(ldo0, 1250, 3300, OFF, NULL);
+static struct regulator_init_data ldo1_data = REGULATOR_INIT(ldo1, 725, 1500, ON, NULL);
+static struct regulator_init_data ldo2_data = REGULATOR_INIT(ldo2, 725, 1500, OFF, NULL);
+static struct regulator_init_data ldo3_data = REGULATOR_INIT(ldo3, 1250, 3300, OFF, NULL);
+static struct regulator_init_data ldo4_data = REGULATOR_INIT(ldo4, 1700, 2475, OFF, NULL);
+static struct regulator_init_data ldo5_data = REGULATOR_INIT(ldo5, 1250, 3300, ON, NULL);
+static struct regulator_init_data ldo6_data = REGULATOR_INIT(ldo6, 1250, 1800, OFF, NULL);
+static struct regulator_init_data ldo7_data = REGULATOR_INIT(ldo7, 1250, 3300, OFF, NULL);
+static struct regulator_init_data ldo8_data = REGULATOR_INIT(ldo8, 1250, 3300, OFF, NULL);
+static struct regulator_init_data ldo9_data = REGULATOR_INIT(ldo9, 1250, 3300, OFF, NULL);
static struct tps6586x_rtc_platform_data rtc_data = {
.irq = TEGRA_NR_IRQS + TPS6586X_INT_RTC_ALM1,