]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
thermal/drivers/intel: Initialize RW trip to THERMAL_TEMP_INVALID
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Fri, 30 Apr 2021 12:23:43 +0000 (05:23 -0700)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Thu, 15 Jul 2021 17:22:33 +0000 (19:22 +0200)
commitd79e0851f324582ead62981982367eb8c3de8fc8
treed5d76c20092b8f7b73cfb1109a190894c925c6ba
parentdb9e1ef3030c6804ff89c8d4a008f76e362f2665
thermal/drivers/intel: Initialize RW trip to THERMAL_TEMP_INVALID

BugLink: https://bugs.launchpad.net/bugs/1931896
commit eb8500b874cf295971a6a2a04e14eb0854197a3c upstream.

After commit 81ad4276b505 ("Thermal: Ignore invalid trip points") all
user_space governor notifications via RW trip point is broken in intel
thermal drivers. This commits marks trip_points with value of 0 during
call to thermal_zone_device_register() as invalid. RW trip points can be
0 as user space will set the correct trip temperature later.

During driver init, x86_package_temp and all int340x drivers sets RW trip
temperature as 0. This results in all these trips marked as invalid by
the thermal core.

To fix this initialize RW trips to THERMAL_TEMP_INVALID instead of 0.

Cc: <stable@vger.kernel.org>
Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20210430122343.1789899-1-srinivas.pandruvada@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
drivers/thermal/intel/x86_pkg_temp_thermal.c