thermal: sensor: fix thermal disabled mode issue [1/1]

PD#SWPL-2130

Problem:
tsensor driver update thermal event when mode disabled

Solution:
fix tsensor disable mode issue

Verify:
A311D W400 pass

Change-Id: If9e3d3ea15732a0efbd8314003b27bc0bdf3e476
Signed-off-by: Huan Biao <huan.biao@amlogic.com>
This commit is contained in:
Huan Biao
2018-11-15 15:24:23 +08:00
committed by Dongjin Kim
parent 68c1e8292a
commit d244915b22

View File

@@ -160,6 +160,12 @@ static void meson_report_trigger(struct meson_tsensor_data *p)
pr_err("No thermal zone device defined\n");
return;
}
/*
*if passive delay and polling delay all is zero
*mean thermal mode disabled, disable update envent
*/
if (0 == (tz->passive_delay || tz->polling_delay))
return;
thermal_zone_device_update(tz, THERMAL_EVENT_UNSPECIFIED);