thermal: of-thermal: disable passive polling when thermal zone is disabled
authorAnson Huang <Anson.Huang@nxp.com>
Mon, 30 Jul 2018 16:56:49 +0000 (00:56 +0800)
committerEduardo Valentin <edubezval@gmail.com>
Mon, 20 Aug 2018 19:00:40 +0000 (12:00 -0700)
commit152395fd03d4ce1e535a75cdbf58105e50587611
tree3cd4e9f026c7072504e8cf867721c24a953b92da
parentd316522d06e9894429ace4b5f99e181bde4e7bd7
thermal: of-thermal: disable passive polling when thermal zone is disabled

When thermal zone is in passive mode, disabling its mode from
sysfs is NOT taking effect at all, it is still polling the
temperature of the disabled thermal zone and handling all thermal
trips, it makes user confused. The disabling operation should
disable the thermal zone behavior completely, for both active and
passive mode, this patch clears the passive_delay when thermal
zone is disabled and restores it when it is enabled.

Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
drivers/thermal/of-thermal.c