summaryrefslogtreecommitdiff
path: root/common/thermal.c
diff options
context:
space:
mode:
authorRyan Zhang <Ryan.Zhang@quanta.corp-partner.google.com>2017-10-20 10:08:12 +0800
committerchrome-bot <chrome-bot@chromium.org>2017-11-06 13:48:38 -0800
commitf48cf0e8b27fb484271540e4cc272aea581a3b48 (patch)
tree08484f3eb500b2f50b0e394101fbb4e5e20225a5 /common/thermal.c
parent1f9b681ac16fd60c245ecd86391f883035cb1037 (diff)
downloadchrome-ec-f48cf0e8b27fb484271540e4cc272aea581a3b48.tar.gz
Fizz: Modify thermal table
Modify thermal table for Fizz reference patches: 627542, 288256, 329359 on off RPM step0 0 step1 16 2 2800 step2 27 18 3200 step3 35 29 3400 step4 43 37 4200 step5 54 45 4800 step6 64 56 5200 step7 97 83 5600 Prochot degree: active when t >= 88C release when t <= 85C Shutdown degree: when t >= 90C BUG=b:67487721, b:64439568 BRANCH=master TEST=fan target speed follows table, make -j buildall pass Change-Id: I3378668a560b8ddc568fe9cbf2703613fad8e4b6 Signed-off-by: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/729606 Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Diffstat (limited to 'common/thermal.c')
-rw-r--r--common/thermal.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/common/thermal.c b/common/thermal.c
index bd9ed7fbf0..7d7438f3e5 100644
--- a/common/thermal.c
+++ b/common/thermal.c
@@ -80,12 +80,17 @@ static void thermal_control(void)
/* check all the limits */
for (j = 0; j < EC_TEMP_THRESH_COUNT; j++) {
int limit = thermal_params[i].temp_host[j];
+ int release = thermal_params[i].temp_host_release[j];
if (limit) {
num_valid_limits[j]++;
- if (t > limit)
+ if (t > limit) {
count_over[j]++;
- else if (t < limit)
+ } else if (release) {
+ if (t < release)
+ count_under[j]++;
+ } else if (t < limit) {
count_under[j]++;
+ }
}
}
@@ -130,7 +135,6 @@ static void thermal_control(void)
cond_set_false(&cond_hot[j]);
}
-
/* What do we do about it? (note hard-coded logic). */
if (cond_went_true(&cond_hot[EC_TEMP_THRESH_HALT])) {