Skip to content

Commit

Permalink
thermal: add imx thermal driver support
Browse files Browse the repository at this point in the history
This is based on the initial imx thermal work done by
Rob Lee <rob.lee@linaro.org> (Not sure if the email address is still
valid).  Since he is no longer interested in the work and I have
rewritten a significant amount of the code, I just took the authorship
over from him.

It adds the imx thermal support using Temperature Monitor (TEMPMON)
block found on some Freescale i.MX SoCs.  The driver uses syscon regmap
interface to access TEMPMON control registers and calibration data, and
supports cpufreq as the cooling device.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Eduardo Valentin <eduardo.valentin@ti.com>
  • Loading branch information
Shawn Guo authored and Eduardo Valentin committed Aug 13, 2013
1 parent ace120d commit ca3de46
Show file tree
Hide file tree
Showing 4 changed files with 426 additions and 0 deletions.
17 changes: 17 additions & 0 deletions Documentation/devicetree/bindings/thermal/imx-thermal.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
* Temperature Monitor (TEMPMON) on Freescale i.MX SoCs

Required properties:
- compatible : "fsl,imx6q-thermal"
- fsl,tempmon : phandle pointer to system controller that contains TEMPMON
control registers, e.g. ANATOP on imx6q.
- fsl,tempmon-data : phandle pointer to fuse controller that contains TEMPMON
calibration data, e.g. OCOTP on imx6q. The details about calibration data
can be found in SoC Reference Manual.

Example:

tempmon {
compatible = "fsl,imx6q-tempmon";
fsl,tempmon = <&anatop>;
fsl,tempmon-data = <&ocotp>;
};
11 changes: 11 additions & 0 deletions drivers/thermal/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,17 @@ config THERMAL_EMULATION
because userland can easily disable the thermal policy by simply
flooding this sysfs node with low temperature values.

config IMX_THERMAL
tristate "Temperature sensor driver for Freescale i.MX SoCs"
depends on CPU_THERMAL
depends on MFD_SYSCON
depends on OF
help
Support for Temperature Monitor (TEMPMON) found on Freescale i.MX SoCs.
It supports one critical trip point and one passive trip point. The
cpufreq is used as the cooling device to throttle CPUs when the
passive trip is crossed.

config SPEAR_THERMAL
bool "SPEAr thermal sensor driver"
depends on PLAT_SPEAR
Expand Down
1 change: 1 addition & 0 deletions drivers/thermal/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ obj-$(CONFIG_EXYNOS_THERMAL) += exynos_thermal.o
obj-$(CONFIG_DOVE_THERMAL) += dove_thermal.o
obj-$(CONFIG_DB8500_THERMAL) += db8500_thermal.o
obj-$(CONFIG_ARMADA_THERMAL) += armada_thermal.o
obj-$(CONFIG_IMX_THERMAL) += imx_thermal.o
obj-$(CONFIG_DB8500_CPUFREQ_COOLING) += db8500_cpufreq_cooling.o
obj-$(CONFIG_INTEL_POWERCLAMP) += intel_powerclamp.o
obj-$(CONFIG_X86_PKG_TEMP_THERMAL) += x86_pkg_temp_thermal.o
Expand Down
Loading

0 comments on commit ca3de46

Please sign in to comment.