This patch changes the dtsi entry on omap4430 to contain
the thermal data. This data will enable the passive
cooling with CPUfreq cooling device at 100C and the
system will do a thermal shutdown at 125C.

Cc: "BenoƮt Cousson" <b-cous...@ti.com>
Cc: Tony Lindgren <t...@atomide.com>
Cc: Russell King <li...@arm.linux.org.uk>
Cc: linux-omap@vger.kernel.org
Cc: devicetree-disc...@lists.ozlabs.org
Cc: linux-arm-ker...@lists.infradead.org
Cc: linux-ker...@vger.kernel.org
Signed-off-by: Eduardo Valentin <eduardo.valen...@ti.com>
---
 arch/arm/boot/dts/omap443x.dtsi | 31 +++++++++++++++++++++++++++++--
 1 file changed, 29 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/omap443x.dtsi b/arch/arm/boot/dts/omap443x.dtsi
index bcf455e..c9a1c89 100644
--- a/arch/arm/boot/dts/omap443x.dtsi
+++ b/arch/arm/boot/dts/omap443x.dtsi
@@ -8,6 +8,7 @@
  * kind, whether express or implied.
  */
 
+#include <dt-bindings/thermal/thermal.h>
 #include "omap4.dtsi"
 
 / {
@@ -26,8 +27,34 @@
        };
 
        bandgap {
-               reg = <0x4a002260 0x4
-                      0x4a00232C 0x4>;
+               reg = <0x4a002260 0x4 0x4a00232C 0x4>;
                compatible = "ti,omap4430-bandgap";
+               thermal_zone {
+                       type = "CPU";
+                       mask = <0x03>; /* trips writability */
+                       passive_delay = <250>; /* milliseconds */
+                       polling_delay = <1000>; /* milliseconds */
+                       governor = "step_wise";
+                       trips {
+                               alert@100000{
+                                       temperature = <100000>; /* milliCelsius 
*/
+                                       hysteresis = <2000>; /* milliCelsius */
+                                       type = <THERMAL_TRIP_PASSIVE>;
+                               };
+                               crit@125000{
+                                       temperature = <125000>; /* milliCelsius 
*/
+                                       hysteresis = <2000>; /* milliCelsius */
+                                       type = <THERMAL_TRIP_CRITICAL>;
+                               };
+                       };
+                       bind_params {
+                               action@0{
+                                       cooling_device = "thermal-cpufreq";
+                                       weight = <100>; /* percentage */
+                                       mask = <0x01>;
+                                       /* no limits, using defaults */
+                               };
+                       };
+               };
        };
 };
-- 
1.8.2.1.342.gfa7285d

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to