]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ACPI: thermal: Switch over to devres-based resource management
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 21 May 2026 14:04:45 +0000 (16:04 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 25 May 2026 14:43:51 +0000 (16:43 +0200)
commitd3f13e75bf2c781b23b8fa8320e5ecb3a0b4df2e
tree5d801f3cfa53a5be4ddd26c8039e26275883d164
parent3159c5fcdd3a5eae70b45cbdf453d408266f547d
ACPI: thermal: Switch over to devres-based resource management

Switch over the ACPI thermal zone driver to devres-based resource
management by making the following changes:

 * Turn acpi_thermal_zone_free() into a devm action added from
   acpi_thermal_probe() after allocating the struct acpi_thermal object.

 * Rename acpi_thermal_unregister_thermal_zone() to
   acpi_thermal_zone_unregister(), add acpi_thermal_pm_queue flushing to
   it, and turn it into a devm action added by acpi_thermal_probe()
   after calling acpi_thermal_register_thermal_zone().

 * Use the newly introduced devm_acpi_install_notify_handler() for
   installing an ACPI notify handler.

 * Drop acpi_thermal_remove() that is not necessary any more.

No intentional functional impact.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://patch.msgid.link/3698719.iIbC2pHGDl@rafael.j.wysocki
drivers/acpi/thermal.c