Lines Matching refs:dts
87 struct intel_soc_dts_sensor_entry *dts; in sys_get_trip_temp() local
90 dts = tzd->devdata; in sys_get_trip_temp()
91 sensors = dts->sensors; in sys_get_trip_temp()
108 static int update_trip_temp(struct intel_soc_dts_sensor_entry *dts, in update_trip_temp() argument
120 struct intel_soc_dts_sensors *sensors = dts->sensors; in update_trip_temp()
181 dts->trip_types[thres_index] = trip_type; in update_trip_temp()
201 struct intel_soc_dts_sensor_entry *dts = tzd->devdata; in sys_set_trip_temp() local
202 struct intel_soc_dts_sensors *sensors = dts->sensors; in sys_set_trip_temp()
210 dts->trip_types[trip]); in sys_set_trip_temp()
219 struct intel_soc_dts_sensor_entry *dts; in sys_get_trip_type() local
221 dts = tzd->devdata; in sys_get_trip_type()
223 *type = dts->trip_types[trip]; in sys_get_trip_type()
233 struct intel_soc_dts_sensor_entry *dts; in sys_get_curr_temp() local
236 dts = tzd->devdata; in sys_get_curr_temp()
237 sensors = dts->sensors; in sys_get_curr_temp()
243 out = (out & dts->temp_mask) >> dts->temp_shift; in sys_get_curr_temp()
278 static void remove_dts_thermal_zone(struct intel_soc_dts_sensor_entry *dts) in remove_dts_thermal_zone() argument
280 if (dts) { in remove_dts_thermal_zone()
282 SOC_DTS_OFFSET_ENABLE, dts->store_status); in remove_dts_thermal_zone()
283 thermal_zone_device_unregister(dts->tzone); in remove_dts_thermal_zone()
287 static int add_dts_thermal_zone(int id, struct intel_soc_dts_sensor_entry *dts, in add_dts_thermal_zone() argument
301 &dts->store_status); in add_dts_thermal_zone()
305 dts->id = id; in add_dts_thermal_zone()
306 dts->temp_mask = 0x00FF << (id * 8); in add_dts_thermal_zone()
307 dts->temp_shift = id * 8; in add_dts_thermal_zone()
325 dts->trip_mask = trip_mask; in add_dts_thermal_zone()
326 dts->trip_count = trip_count; in add_dts_thermal_zone()
328 dts->tzone = thermal_zone_device_register(name, in add_dts_thermal_zone()
331 dts, &tzone_ops, in add_dts_thermal_zone()
333 if (IS_ERR(dts->tzone)) { in add_dts_thermal_zone()
334 ret = PTR_ERR(dts->tzone); in add_dts_thermal_zone()
344 thermal_zone_device_unregister(dts->tzone); in add_dts_thermal_zone()