]> git.ipfire.org Git - thirdparty/linux.git/commit
thermal/core: Add dedicated release callback for thermal zones
authorDaniel Lezcano <daniel.lezcano@oss.qualcomm.com>
Fri, 8 May 2026 18:05:09 +0000 (20:05 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 13 May 2026 19:03:15 +0000 (21:03 +0200)
commitdc04e81fa2188d96af0c795ff45e4e5a209183b2
treeb271169a443063516cbfef26726f661eefacb497
parent11568924a9319c951f7086c002741c03d4d0f740
thermal/core: Add dedicated release callback for thermal zones

The thermal class release callback currently handles thermal zone
cleanup by checking the device name prefix.

Move the thermal zone cleanup to a dedicated struct device release
callback.  This avoids relying on device names to select the release
path and keeps the thermal zone lifetime handling local to the thermal
zone object.

Signed-off-by: Daniel Lezcano <daniel.lezcano@oss.qualcomm.com>
Reviewed-by: Lukasz Luba <lukasz.luba@arm.com>
Link: https://patch.msgid.link/20260508180511.1306659-3-daniel.lezcano@oss.qualcomm.com
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/thermal/thermal_core.c