[9810] thermal: fix recursive mutex_lock by cpu hotplug notifier
authorEunseok Choi <es10.choi@samsung.com>
Tue, 5 Dec 2017 11:06:00 +0000 (20:06 +0900)
committerChungwoo Park <cww.park@samsung.com>
Mon, 21 May 2018 08:22:09 +0000 (17:22 +0900)
Change-Id: I303f7a0e3a811f1de728605fa2332c800e445889
Signed-off-by: Eunseok Choi <es10.choi@samsung.com>
drivers/thermal/thermal_core.c

index 4ec25e9b21df044f9127fd75f06f11614f347fc2..c60989baedc8aa67c6e3dd9efea0c55df6d9745f 100644 (file)
@@ -496,8 +496,10 @@ void thermal_zone_device_update(struct thermal_zone_device *tz,
                for (count = 0; count < tz->trips; count++)
                        handle_thermal_trip(tz, count);
 
-               if (tz->ops->throttle_hotplug)
-                       tz->ops->throttle_hotplug(tz);
+               if (event != THERMAL_DEVICE_POWER_CAPABILITY_CHANGED) {
+                       if (tz->ops->throttle_hotplug)
+                               tz->ops->throttle_hotplug(tz);
+               }
        }
 }
 EXPORT_SYMBOL_GPL(thermal_zone_device_update);