thermal: core: Introduce thermal_cooling_device_present()
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 17 Mar 2023 16:54:34 +0000 (17:54 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 22 Mar 2023 14:20:38 +0000 (15:20 +0100)
commitc43198af05cffa5de8d4f356c40ce4bdca066272
treea9d7fcab9437c04c940e698d7f11d13de5244597
parentc0e0421a60bf468e88cf569fbd727346b138ed04
thermal: core: Introduce thermal_cooling_device_present()

Introduce a helper function, thermal_cooling_device_present(), for
checking if the given cooling device is in the list of registered
cooling devices to avoid some code duplication in a subsequent
patch.

No expected functional impact.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Tested-by: Zhang Rui <rui.zhang@intel.com>
Reviewed-by: Zhang Rui <rui.zhang@intel.com>
drivers/thermal/thermal_core.c