thermal: intel: intel_soc_dts_iosf: Use struct thermal_trip
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 10 Aug 2023 19:17:36 +0000 (21:17 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 11 Aug 2023 16:44:45 +0000 (18:44 +0200)
commit4effd28e61e768bcc2017c58cd23bd0846649ac4
tree274dd31ae03146a7754fa3729918ce74e9a541ae
parent02a49aaceff4a229d775b82ccaaafe59fe16b8f5
thermal: intel: intel_soc_dts_iosf: Use struct thermal_trip

Because the number of trip points in each thermal zone and their
types are known to intel_soc_dts_iosf_init() prior to the registration
of the thermal zones, make it create an array of struct thermal_trip
entries in each struct intel_soc_dts_sensor_entry object and make
add_dts_thermal_zone() use thermal_zone_device_register_with_trips()
for thermal zone registration and pass that array as its second
argument.

Drop the sys_get_trip_temp() and sys_get_trip_type() callback
functions along with the respective callback pointers in
tzone_ops, because they are not necessary any more.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
drivers/thermal/intel/intel_soc_dts_iosf.c
drivers/thermal/intel/intel_soc_dts_iosf.h