thermal: core: Drop thermal_zone_device_exec()
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 3 Oct 2023 13:25:33 +0000 (15:25 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 5 Oct 2023 11:32:55 +0000 (13:32 +0200)
Because thermal_zone_device_exec() has no users any more and there are
no plans to use it anywhere, revert commit 9a99a996d1ec ("thermal: core:
Introduce thermal_zone_device_exec()") that introduced it.

No functional impact.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
drivers/thermal/thermal_core.c
include/linux/thermal.h

index 45d0aa0b69b79c0fd21ba4643280e3dd7da19deb..8ee22eb804d35ad9d1adcbd6ad5c1a938bde3735 100644 (file)
@@ -495,25 +495,6 @@ void thermal_zone_device_update(struct thermal_zone_device *tz,
 }
 EXPORT_SYMBOL_GPL(thermal_zone_device_update);
 
-/**
- * thermal_zone_device_exec - Run a callback under the zone lock.
- * @tz: Thermal zone.
- * @cb: Callback to run.
- * @data: Data to pass to the callback.
- */
-void thermal_zone_device_exec(struct thermal_zone_device *tz,
-                             void (*cb)(struct thermal_zone_device *,
-                                        unsigned long),
-                             unsigned long data)
-{
-       mutex_lock(&tz->lock);
-
-       cb(tz, data);
-
-       mutex_unlock(&tz->lock);
-}
-EXPORT_SYMBOL_GPL(thermal_zone_device_exec);
-
 static void thermal_zone_device_check(struct work_struct *work)
 {
        struct thermal_zone_device *tz = container_of(work, struct
index 2bab72149bbfe142b64cf975dd291d3213048769..c8600e313909ed5ca1f5ac42355134a8ac6b02b9 100644 (file)
@@ -339,10 +339,6 @@ int thermal_zone_unbind_cooling_device(struct thermal_zone_device *, int,
                                       struct thermal_cooling_device *);
 void thermal_zone_device_update(struct thermal_zone_device *,
                                enum thermal_notify_event);
-void thermal_zone_device_exec(struct thermal_zone_device *tz,
-                             void (*cb)(struct thermal_zone_device *,
-                                        unsigned long),
-                             unsigned long data);
 
 struct thermal_cooling_device *thermal_cooling_device_register(const char *,
                void *, const struct thermal_cooling_device_ops *);