ACPI: thermal: Simplify initialization of critical and hot trips
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 12 Sep 2023 18:35:40 +0000 (20:35 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 26 Sep 2023 15:56:12 +0000 (17:56 +0200)
commit4be32333d941a53dcfb48e342c808c63a3b25576
tree1b26118c6e47dfd27803d969361801e0bde4e62e
parent6465e260f48790807eef06b583b38ca9789b6072
ACPI: thermal: Simplify initialization of critical and hot trips

Use the observation that the critical and hot trip points are never
updated by the ACPI thermal driver, because the flags passed from
acpi_thermal_notify() to acpi_thermal_trips_update() do not include
ACPI_TRIPS_CRITICAL or ACPI_TRIPS_HOT, to move the initialization
of those trip points directly into acpi_thermal_get_trip_points() and
reduce the size of __acpi_thermal_trips_update().

Also make the critical and hot trip points initialization code more
straightforward and drop the flags that are not needed any more.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Daniel Lezcano <daniel.lezcano@linaro.org>
drivers/acpi/thermal.c