Skip to content

Commit 54bc46b

Browse files
Josh-Tsaiamstan
authored andcommitted
fwk: temp_sensor: allow second SB-TSI sensor
BRANCH=fwk-dogwood-27111 BUG=None TEST=build two SB-TSI sensor pass Signed-off-by: Josh Tsai <Josh_Tsai@compal.com>
1 parent 8de0b40 commit 54bc46b

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

zephyr/shim/src/temp_sensors.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -168,8 +168,11 @@ __maybe_unused static int sb_tsi_get_temp(const struct temp_sensor_t *sensor,
168168
return sb_tsi_get_val(sensor->idx, temp_ptr);
169169
}
170170

171-
/* There can be only one SB TSI sensor with current driver */
172-
#if DT_NUM_INST_STATUS_OKAY(SB_TSI_COMPAT) > 1
171+
/**
172+
* There can be only two SB TSI sensor with current driver
173+
* (one for virtual temperature sensor).
174+
*/
175+
#if DT_NUM_INST_STATUS_OKAY(SB_TSI_COMPAT) > 2
173176
#error "Unsupported number of SB TSI sensors"
174177
#endif
175178

0 commit comments

Comments
 (0)