pm8998.dtsi 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
  2. /* Copyright 2018 Google LLC. */
  3. #include <dt-bindings/iio/qcom,spmi-vadc.h>
  4. #include <dt-bindings/input/linux-event-codes.h>
  5. #include <dt-bindings/interrupt-controller/irq.h>
  6. #include <dt-bindings/spmi/spmi.h>
  7. #include <dt-bindings/thermal/thermal.h>
  8. / {
  9. thermal-zones {
  10. pm8998-thermal {
  11. polling-delay-passive = <250>;
  12. polling-delay = <1000>;
  13. thermal-sensors = <&pm8998_temp>;
  14. trips {
  15. pm8998_alert0: pm8998-alert0 {
  16. temperature = <105000>;
  17. hysteresis = <2000>;
  18. type = "passive";
  19. };
  20. pm8998_crit: pm8998-crit {
  21. temperature = <125000>;
  22. hysteresis = <2000>;
  23. type = "critical";
  24. };
  25. };
  26. };
  27. };
  28. };
  29. &spmi_bus {
  30. pm8998_lsid0: pmic@0 {
  31. compatible = "qcom,pm8998", "qcom,spmi-pmic";
  32. reg = <0x0 SPMI_USID>;
  33. #address-cells = <1>;
  34. #size-cells = <0>;
  35. pm8998_pon: pon@800 {
  36. compatible = "qcom,pm8998-pon";
  37. reg = <0x800>;
  38. mode-bootloader = <0x2>;
  39. mode-recovery = <0x1>;
  40. pm8998_pwrkey: pwrkey {
  41. compatible = "qcom,pm8941-pwrkey";
  42. interrupts = <0x0 0x8 0 IRQ_TYPE_EDGE_BOTH>;
  43. debounce = <15625>;
  44. bias-pull-up;
  45. linux,code = <KEY_POWER>;
  46. };
  47. };
  48. pm8998_temp: temp-alarm@2400 {
  49. compatible = "qcom,spmi-temp-alarm";
  50. reg = <0x2400>;
  51. interrupts = <0x0 0x24 0x0 IRQ_TYPE_EDGE_RISING>;
  52. io-channels = <&pm8998_adc ADC5_DIE_TEMP>;
  53. io-channel-names = "thermal";
  54. #thermal-sensor-cells = <0>;
  55. };
  56. pm8998_coincell: coincell@2800 {
  57. compatible = "qcom,pm8941-coincell";
  58. reg = <0x2800>;
  59. status = "disabled";
  60. };
  61. pm8998_adc: adc@3100 {
  62. compatible = "qcom,spmi-adc-rev2";
  63. reg = <0x3100>;
  64. interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
  65. #address-cells = <1>;
  66. #size-cells = <0>;
  67. #io-channel-cells = <1>;
  68. adc-chan@6 {
  69. reg = <ADC5_DIE_TEMP>;
  70. label = "die_temp";
  71. };
  72. };
  73. pm8998_adc_tm: adc-tm@3400 {
  74. compatible = "qcom,spmi-adc-tm-hc";
  75. reg = <0x3400>;
  76. interrupts = <0x0 0x34 0x0 IRQ_TYPE_EDGE_RISING>;
  77. #thermal-sensor-cells = <1>;
  78. #address-cells = <1>;
  79. #size-cells = <0>;
  80. status = "disabled";
  81. };
  82. rtc@6000 {
  83. compatible = "qcom,pm8941-rtc";
  84. reg = <0x6000>, <0x6100>;
  85. reg-names = "rtc", "alarm";
  86. interrupts = <0x0 0x61 0x1 IRQ_TYPE_EDGE_RISING>;
  87. };
  88. pm8998_gpio: gpios@c000 {
  89. compatible = "qcom,pm8998-gpio", "qcom,spmi-gpio";
  90. reg = <0xc000>;
  91. gpio-controller;
  92. gpio-ranges = <&pm8998_gpio 0 0 26>;
  93. #gpio-cells = <2>;
  94. interrupt-controller;
  95. #interrupt-cells = <2>;
  96. };
  97. };
  98. pm8998_lsid1: pmic@1 {
  99. compatible = "qcom,pm8998", "qcom,spmi-pmic";
  100. reg = <0x1 SPMI_USID>;
  101. #address-cells = <1>;
  102. #size-cells = <0>;
  103. };
  104. };