summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mainboard/google/gru/pwm_regulator.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/mainboard/google/gru/pwm_regulator.c b/src/mainboard/google/gru/pwm_regulator.c
index 696f09a206..3ee74a4426 100644
--- a/src/mainboard/google/gru/pwm_regulator.c
+++ b/src/mainboard/google/gru/pwm_regulator.c
@@ -32,7 +32,7 @@
#define PWM_DESIGN_VOLTAGE_MIN_OUTDATED 8000
#define PWM_DESIGN_VOLTAGE_MAX_OUTDATED 15000
-/* Later boards (Kevin rev6+, Gru rev2+) use different regulator ranges. */
+/* Applies for Kevin rev6+ */
int kevin6_pwm_design_voltage[][2] = {
[PWM_REGULATOR_GPU] = {7858, 12177},
[PWM_REGULATOR_BIG] = {7987, 13022},
@@ -40,6 +40,7 @@ int kevin6_pwm_design_voltage[][2] = {
[PWM_REGULATOR_CENTERLOG] = {8001, 10497}
};
+/* Applies for Gru rev2+ and Bob. */
int pwm_design_voltage[][2] = {
[PWM_REGULATOR_GPU] = {7864, 12177},
[PWM_REGULATOR_BIG] = {8001, 13022},
@@ -47,6 +48,13 @@ int pwm_design_voltage[][2] = {
[PWM_REGULATOR_CENTERLOG] = {7994, 10499}
};
+/* Applies for Scarlet */
+int scarlet_pwm_design_voltage[][2] = {
+ [PWM_REGULATOR_GPU] = {7996, 10990},
+ [PWM_REGULATOR_BIG] = {8000, 12992},
+ [PWM_REGULATOR_LIT] = {8021, 11996},
+};
+
int pwm_enum_to_pwm_number[] = {
[PWM_REGULATOR_GPU] = 0,
[PWM_REGULATOR_LIT] = 2,
@@ -74,6 +82,9 @@ void pwm_regulator_configure(enum pwm_regulator pwm, int millivolt)
} else if (IS_ENABLED(CONFIG_BOARD_GOOGLE_KEVIN) && board_id() >= 6) {
voltage_min = kevin6_pwm_design_voltage[pwm][0];
voltage_max = kevin6_pwm_design_voltage[pwm][1];
+ } else if (IS_ENABLED(CONFIG_BOARD_GOOGLE_SCARLET)) {
+ voltage_min = scarlet_pwm_design_voltage[pwm][0];
+ voltage_max = scarlet_pwm_design_voltage[pwm][1];
}
assert(voltage <= voltage_max && voltage >= voltage_min);