From 81a059a8c6a0cb804b3677b76444f9fae28c53f9 Mon Sep 17 00:00:00 2001 From: Jinyoung Park Date: Thu, 29 May 2014 02:58:13 +0900 Subject: [PATCH] misc: therm_est: Unregister tz and cdev in shutdown Unregister thermal zone and cooling device in shutdown callback to prevent unwanted thermal operating while shutdown processing. Bug 1515432 Change-Id: I49a13618f7b8f8d5b55a8e960676e7357891fe89 Signed-off-by: Jinyoung Park Reviewed-on: http://git-master/r/416278 (cherry picked from commit cb140feb445ff6dce4984bed527eca56191180a8) Reviewed-on: http://git-master/r/436687 GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan --- drivers/misc/therm_est.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/misc/therm_est.c b/drivers/misc/therm_est.c index 7c47658bde9..48f5786e656 100644 --- a/drivers/misc/therm_est.c +++ b/drivers/misc/therm_est.c @@ -885,6 +885,8 @@ static void therm_est_shutdown(struct platform_device *pdev) cancel_delayed_work_sync(&est->therm_est_work); cancel_delayed_work_sync(&est->timer_trip_work); + thermal_zone_device_unregister(est->thz); + thermal_cooling_device_unregister(est->cdev); } static struct platform_driver therm_est_driver = { -- 2.39.2