diff options
Diffstat (limited to 'board/genesis/board.c')
-rw-r--r-- | board/genesis/board.c | 35 |
1 files changed, 20 insertions, 15 deletions
diff --git a/board/genesis/board.c b/board/genesis/board.c index 2a44d4416a..a846478ecb 100644 --- a/board/genesis/board.c +++ b/board/genesis/board.c @@ -227,23 +227,28 @@ BUILD_ASSERT(ARRAY_SIZE(mft_channels) == MFT_CH_COUNT); /******************************************************************************/ /* Thermal control; drive fan based on temperature sensors. */ -const static struct ec_thermal_config thermal_a = { - .temp_host = { - [EC_TEMP_THRESH_WARN] = 0, - [EC_TEMP_THRESH_HIGH] = C_TO_K(78), - [EC_TEMP_THRESH_HALT] = C_TO_K(85), - }, - .temp_host_release = { - [EC_TEMP_THRESH_WARN] = 0, - [EC_TEMP_THRESH_HIGH] = C_TO_K(70), - [EC_TEMP_THRESH_HALT] = 0, - }, - .temp_fan_off = C_TO_K(25), - .temp_fan_max = C_TO_K(84), -}; +/* + * TODO(b/202062363): Remove when clang is fixed. + */ +#define THERMAL_A \ + { \ + .temp_host = { \ + [EC_TEMP_THRESH_WARN] = 0, \ + [EC_TEMP_THRESH_HIGH] = C_TO_K(78), \ + [EC_TEMP_THRESH_HALT] = C_TO_K(85), \ + }, \ + .temp_host_release = { \ + [EC_TEMP_THRESH_WARN] = 0, \ + [EC_TEMP_THRESH_HIGH] = C_TO_K(70), \ + [EC_TEMP_THRESH_HALT] = 0, \ + }, \ + .temp_fan_off = C_TO_K(25), \ + .temp_fan_max = C_TO_K(84), \ + } +__maybe_unused static const struct ec_thermal_config thermal_a = THERMAL_A; struct ec_thermal_config thermal_params[] = { - [TEMP_SENSOR_CORE] = thermal_a, + [TEMP_SENSOR_CORE] = THERMAL_A, }; BUILD_ASSERT(ARRAY_SIZE(thermal_params) == TEMP_SENSOR_COUNT); |