rockchip-thermal.txt 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. * Temperature Sensor ADC (TSADC) on rockchip SoCs
  2. Required properties:
  3. - compatible : "rockchip,rk3288-tsadc"
  4. - reg : physical base address of the controller and length of memory mapped
  5. region.
  6. - interrupts : The interrupt number to the cpu. The interrupt specifier format
  7. depends on the interrupt controller.
  8. - clocks : Must contain an entry for each entry in clock-names.
  9. - clock-names : Shall be "tsadc" for the converter-clock, and "apb_pclk" for
  10. the peripheral clock.
  11. - resets : Must contain an entry for each entry in reset-names.
  12. See ../reset/reset.txt for details.
  13. - reset-names : Must include the name "tsadc-apb".
  14. - #thermal-sensor-cells : Should be 1. See ./thermal.txt for a description.
  15. - rockchip,hw-tshut-temp : The hardware-controlled shutdown temperature value.
  16. - rockchip,hw-tshut-mode : The hardware-controlled shutdown mode 0:CRU 1:GPIO.
  17. - rockchip,hw-tshut-polarity : The hardware-controlled active polarity 0:LOW
  18. 1:HIGH.
  19. Exiample:
  20. tsadc: tsadc@ff280000 {
  21. compatible = "rockchip,rk3288-tsadc";
  22. reg = <0xff280000 0x100>;
  23. interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
  24. clocks = <&cru SCLK_TSADC>, <&cru PCLK_TSADC>;
  25. clock-names = "tsadc", "apb_pclk";
  26. resets = <&cru SRST_TSADC>;
  27. reset-names = "tsadc-apb";
  28. pinctrl-names = "default";
  29. pinctrl-0 = <&otp_out>;
  30. #thermal-sensor-cells = <1>;
  31. rockchip,hw-tshut-temp = <95000>;
  32. rockchip,hw-tshut-mode = <0>;
  33. rockchip,hw-tshut-polarity = <0>;
  34. };
  35. Example: referring to thermal sensors:
  36. thermal-zones {
  37. cpu_thermal: cpu_thermal {
  38. polling-delay-passive = <1000>; /* milliseconds */
  39. polling-delay = <5000>; /* milliseconds */
  40. /* sensor ID */
  41. thermal-sensors = <&tsadc 1>;
  42. trips {
  43. cpu_alert0: cpu_alert {
  44. temperature = <70000>; /* millicelsius */
  45. hysteresis = <2000>; /* millicelsius */
  46. type = "passive";
  47. };
  48. cpu_crit: cpu_crit {
  49. temperature = <90000>; /* millicelsius */
  50. hysteresis = <2000>; /* millicelsius */
  51. type = "critical";
  52. };
  53. };
  54. cooling-maps {
  55. map0 {
  56. trip = <&cpu_alert0>;
  57. cooling-device =
  58. <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
  59. };
  60. };
  61. };
  62. };