summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoramber.chen <amber.chen@lcfc.corp-partner.google.com>2021-09-08 17:02:16 +0800
committerCommit Bot <commit-bot@chromium.org>2021-09-23 22:31:37 +0000
commit9d98d6bd5650479a8bac5dce367aa7855a42bf53 (patch)
tree4973d640c5537d1eb262c26e66a4d219edecad81
parentedd45ac7f50626a84158e6248eca787aa45de291 (diff)
downloadchrome-ec-9d98d6bd5650479a8bac5dce367aa7855a42bf53.tar.gz
taeko/taeland: add fan control
BUG=b:194774929 BRANCH=main TEST=make -j BOARD=taeko Signed-off-by: amber.chen <amber.chen@lcfc.corp-partner.google.com> Change-Id: Iaefd277fe17dcf3bebbcd304f6eb7fb33f72cab7 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3146779 Reviewed-by: YH Lin <yueherngl@chromium.org> Reviewed-by: Boris Mittelberg <bmbm@google.com> Commit-Queue: Boris Mittelberg <bmbm@google.com>
-rw-r--r--board/taeko/board.h12
-rw-r--r--board/taeko/gpio.inc2
-rw-r--r--board/taeko/sensors.c10
3 files changed, 3 insertions, 21 deletions
diff --git a/board/taeko/board.h b/board/taeko/board.h
index e76606fc2a..61d716ab79 100644
--- a/board/taeko/board.h
+++ b/board/taeko/board.h
@@ -160,11 +160,8 @@
#define CONFIG_TEMP_SENSOR_POWER_GPIO GPIO_SEQ_EC_DSW_PWROK
#define CONFIG_STEINHART_HART_3V3_30K9_47K_4050B
-/*
- * TODO:(b/194774929)
- * no fan control loop until sensors are tuned
- */
-/* #define CONFIG_FANS FAN_CH_COUNT */
+/* Fan */
+#define CONFIG_FANS FAN_CH_COUNT
/* Charger defines */
#define CONFIG_CHARGER_BQ25720
@@ -190,13 +187,8 @@ enum adc_channel {
enum temp_sensor_id {
TEMP_SENSOR_1_DDR_SOC,
TEMP_SENSOR_2_FAN,
-#if 0
-/*
- * TOOD(b/194774929): need to update for real fan
- */
TEMP_SENSOR_3_CHARGER,
TEMP_SENSOR_4_WWAN,
-#endif
TEMP_SENSOR_COUNT
};
diff --git a/board/taeko/gpio.inc b/board/taeko/gpio.inc
index 94cea8b434..7e97007af6 100644
--- a/board/taeko/gpio.inc
+++ b/board/taeko/gpio.inc
@@ -64,7 +64,7 @@ GPIO(EC_PCH_RTCRST, PIN(7, 6), GPIO_OUT_LOW)
GPIO(EC_PCH_SYS_PWROK, PIN(3, 7), GPIO_OUT_LOW)
GPIO(EC_PCH_WAKE_R_ODL, PIN(C, 0), GPIO_ODR_HIGH)
GPIO(EC_PROCHOT_ODL, PIN(6, 3), GPIO_ODR_HIGH)
-GPIO(EN_PP5000_FAN, PIN(6, 1), GPIO_OUT_HIGH)
+GPIO(EN_PP5000_FAN, PIN(6, 1), GPIO_OUT_LOW)
GPIO(EN_PP5000_USBA_R, PIN(D, 7), GPIO_OUT_LOW)
GPIO(EN_S5_RAILS, PIN(B, 6), GPIO_OUT_LOW)
GPIO(IMVP9_VRRDY_OD, PIN(4, 3), GPIO_INPUT)
diff --git a/board/taeko/sensors.c b/board/taeko/sensors.c
index a199f18fcc..66b182b472 100644
--- a/board/taeko/sensors.c
+++ b/board/taeko/sensors.c
@@ -285,10 +285,6 @@ const struct temp_sensor_t temp_sensors[] = {
.read = get_temp_3v3_30k9_47k_4050b,
.idx = ADC_TEMP_SENSOR_2_FAN
},
-#if 0
-/*
- * TOOD(b/194774929): need to update for real fan
- */
[TEMP_SENSOR_3_CHARGER] = {
.name = "CHARGER",
.type = TEMP_SENSOR_TYPE_BOARD,
@@ -301,7 +297,6 @@ const struct temp_sensor_t temp_sensors[] = {
.read = get_temp_3v3_30k9_47k_4050b,
.idx = ADC_TEMP_SENSOR_4_WWAN
},
-#endif
};
@@ -355,13 +350,8 @@ static const struct ec_thermal_config thermal_fan = {
struct ec_thermal_config thermal_params[] = {
[TEMP_SENSOR_1_DDR_SOC] = thermal_cpu,
[TEMP_SENSOR_2_FAN] = thermal_fan,
-#if 0
-/*
- * TOOD(b/194774929): need to update for real fan
- */
[TEMP_SENSOR_3_CHARGER] = thermal_fan,
[TEMP_SENSOR_4_WWAN] = thermal_fan,
-#endif
};
BUILD_ASSERT(ARRAY_SIZE(thermal_params) == TEMP_SENSOR_COUNT);