thermal: Enhance thermal_zone_device_update for events
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Fri, 26 Aug 2016 23:21:16 +0000 (16:21 -0700)
committerZhang Rui <rui.zhang@intel.com>
Tue, 27 Sep 2016 06:35:21 +0000 (14:35 +0800)
commit0e70f466fb910ae54c4c71243b99385129e93feb
treebe1535a5675f7afa8a09cd09a119fddaeb24d662
parent040a3eadf00b4993fb215fba1d788c91712401ba
thermal: Enhance thermal_zone_device_update for events

Added one additional parameter to thermal_zone_device_update() to provide
caller with an optional capability to specify reason.
Currently this event is used by user space governor to trigger different
processing based on event code. Also it saves an additional call to read
temperature when the event is received.
The following events are cuurently defined:
- Unspecified event
- New temperature sample
- Trip point violated
- Trip point changed
- thermal device up and down
- thermal device power capability changed

Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
20 files changed:
drivers/acpi/thermal.c
drivers/platform/x86/acerhdf.c
drivers/regulator/max8973-regulator.c
drivers/thermal/db8500_thermal.c
drivers/thermal/hisi_thermal.c
drivers/thermal/imx_thermal.c
drivers/thermal/int340x_thermal/int340x_thermal_zone.h
drivers/thermal/intel_bxt_pmic_thermal.c
drivers/thermal/intel_soc_dts_iosf.c
drivers/thermal/max77620_thermal.c
drivers/thermal/of-thermal.c
drivers/thermal/qcom-spmi-temp-alarm.c
drivers/thermal/rcar_thermal.c
drivers/thermal/rockchip_thermal.c
drivers/thermal/samsung/exynos_tmu.c
drivers/thermal/st/st_thermal_memmap.c
drivers/thermal/thermal_core.c
drivers/thermal/ti-soc-thermal/ti-thermal-common.c
drivers/thermal/x86_pkg_temp_thermal.c
include/linux/thermal.h