[coreboot-gerrit] Change in coreboot[master]: google/gru: Correct Scarlet pwm regulator minimum value and maximum v...

Lin Huang (Code Review) gerrit at coreboot.org
Mon Jul 31 09:25:56 CEST 2017


Lin Huang has uploaded this change for review. ( https://review.coreboot.org/20831


Change subject: google/gru: Correct Scarlet pwm regulator minimum value and maximum value
......................................................................

google/gru: Correct Scarlet pwm regulator minimum value and maximum value

In Scarlet pwm regulatoror minimum value and maximum value differs from
other board variants, Correct it so we can get the right voltage.

Change-Id: I1f722eabb697b3438d9f4aa29c205b0161eb442a
Signed-off-by: Lin Huang <hl at rock-chips.com>
---
M src/mainboard/google/gru/pwm_regulator.c
1 file changed, 9 insertions(+), 0 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/31/20831/1

diff --git a/src/mainboard/google/gru/pwm_regulator.c b/src/mainboard/google/gru/pwm_regulator.c
index 696f09a..729c1fe 100644
--- a/src/mainboard/google/gru/pwm_regulator.c
+++ b/src/mainboard/google/gru/pwm_regulator.c
@@ -47,6 +47,12 @@
 	[PWM_REGULATOR_CENTERLOG] = {7994, 10499}
 };
 
+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 +80,9 @@
 	} 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);

-- 
To view, visit https://review.coreboot.org/20831
To unsubscribe, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I1f722eabb697b3438d9f4aa29c205b0161eb442a
Gerrit-Change-Number: 20831
Gerrit-PatchSet: 1
Gerrit-Owner: Lin Huang <hl at rock-chips.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20170731/0fcb0b33/attachment-0001.html>


More information about the coreboot-gerrit mailing list