]> www.infradead.org Git - users/jedix/linux-maple.git/commit
thermal: core: Add and use cooling device guard
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 14 Oct 2024 14:59:46 +0000 (16:59 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 24 Oct 2024 12:48:23 +0000 (14:48 +0200)
commita5a98a786e5e31e85a69d30935254e8730734706
tree6654682d011b2466324507b7b3fa1ae824ab44d2
parentc597b4e74b124aebf7e3d3f7907e2d4779d870e3
thermal: core: Add and use cooling device guard

Add and use a special guard for cooling devices.

This allows quite a few error code paths to be simplified among
other things and brings in code size reduction for a good measure.

No intentional functional impact.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://patch.msgid.link/5837621.DvuYhMxLoT@rjwysocki.net
Reviewed-by: Lukasz Luba <lukasz.luba@arm.com>
drivers/thermal/gov_power_allocator.c
drivers/thermal/gov_step_wise.c
drivers/thermal/thermal_core.c
drivers/thermal/thermal_debugfs.c
drivers/thermal/thermal_helpers.c
drivers/thermal/thermal_sysfs.c
include/linux/thermal.h