samsung,s2mps11.yaml 7.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267
  1. # SPDX-License-Identifier: GPL-2.0-only
  2. %YAML 1.2
  3. ---
  4. $id: http://devicetree.org/schemas/mfd/samsung,s2mps11.yaml#
  5. $schema: http://devicetree.org/meta-schemas/core.yaml#
  6. title: Samsung S2MPS11/13/14/15 and S2MPU02 Power Management IC
  7. maintainers:
  8. - Krzysztof Kozlowski <krzk@kernel.org>
  9. description: |
  10. This is a part of device tree bindings for S2M and S5M family of Power
  11. Management IC (PMIC).
  12. The Samsung S2MPS11/13/14/15 and S2MPU02 is a family of Power Management IC
  13. which include voltage and current regulators, RTC, clock outputs and other
  14. sub-blocks.
  15. properties:
  16. compatible:
  17. enum:
  18. - samsung,s2mps11-pmic
  19. - samsung,s2mps13-pmic
  20. - samsung,s2mps14-pmic
  21. - samsung,s2mps15-pmic
  22. - samsung,s2mpu02-pmic
  23. clocks:
  24. $ref: /schemas/clock/samsung,s2mps11.yaml
  25. description:
  26. Child node describing clock provider.
  27. interrupts:
  28. maxItems: 1
  29. reg:
  30. maxItems: 1
  31. regulators:
  32. type: object
  33. description:
  34. List of child nodes that specify the regulators.
  35. samsung,s2mps11-acokb-ground:
  36. description: |
  37. Indicates that ACOKB pin of S2MPS11 PMIC is connected to the ground so
  38. the PMIC must manually set PWRHOLD bit in CTRL1 register to turn off the
  39. power. Usually the ACOKB is pulled up to VBATT so when PWRHOLD pin goes
  40. low, the rising ACOKB will trigger power off.
  41. type: boolean
  42. samsung,s2mps11-wrstbi-ground:
  43. description: |
  44. Indicates that WRSTBI pin of PMIC is pulled down. When the system is
  45. suspended it will always go down thus triggering unwanted buck warm
  46. reset (setting buck voltages to default values).
  47. type: boolean
  48. wakeup-source: true
  49. required:
  50. - compatible
  51. - reg
  52. - regulators
  53. additionalProperties: false
  54. allOf:
  55. - if:
  56. properties:
  57. compatible:
  58. contains:
  59. const: samsung,s2mps11-pmic
  60. then:
  61. properties:
  62. regulators:
  63. $ref: /schemas/regulator/samsung,s2mps11.yaml
  64. samsung,s2mps11-wrstbi-ground: false
  65. - if:
  66. properties:
  67. compatible:
  68. contains:
  69. const: samsung,s2mps13-pmic
  70. then:
  71. properties:
  72. regulators:
  73. $ref: /schemas/regulator/samsung,s2mps13.yaml
  74. samsung,s2mps11-acokb-ground: false
  75. - if:
  76. properties:
  77. compatible:
  78. contains:
  79. const: samsung,s2mps14-pmic
  80. then:
  81. properties:
  82. regulators:
  83. $ref: /schemas/regulator/samsung,s2mps14.yaml
  84. samsung,s2mps11-acokb-ground: false
  85. samsung,s2mps11-wrstbi-ground: false
  86. - if:
  87. properties:
  88. compatible:
  89. contains:
  90. const: samsung,s2mps15-pmic
  91. then:
  92. properties:
  93. regulators:
  94. $ref: /schemas/regulator/samsung,s2mps15.yaml
  95. samsung,s2mps11-acokb-ground: false
  96. samsung,s2mps11-wrstbi-ground: false
  97. - if:
  98. properties:
  99. compatible:
  100. contains:
  101. const: samsung,s2mpu02-pmic
  102. then:
  103. properties:
  104. regulators:
  105. $ref: /schemas/regulator/samsung,s2mpu02.yaml
  106. samsung,s2mps11-acokb-ground: false
  107. samsung,s2mps11-wrstbi-ground: false
  108. examples:
  109. - |
  110. #include <dt-bindings/interrupt-controller/irq.h>
  111. i2c {
  112. #address-cells = <1>;
  113. #size-cells = <0>;
  114. pmic@66 {
  115. compatible = "samsung,s2mps11-pmic";
  116. reg = <0x66>;
  117. interrupt-parent = <&gpx0>;
  118. interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
  119. pinctrl-names = "default";
  120. pinctrl-0 = <&s2mps11_irq>;
  121. samsung,s2mps11-acokb-ground;
  122. wakeup-source;
  123. clocks {
  124. compatible = "samsung,s2mps11-clk";
  125. #clock-cells = <1>;
  126. clock-output-names = "s2mps11_ap", "s2mps11_cp", "s2mps11_bt";
  127. };
  128. regulators {
  129. LDO1 {
  130. regulator-name = "vdd_ldo1";
  131. regulator-min-microvolt = <1000000>;
  132. regulator-max-microvolt = <1000000>;
  133. regulator-always-on;
  134. };
  135. LDO4 {
  136. regulator-name = "vdd_adc";
  137. regulator-min-microvolt = <1800000>;
  138. regulator-max-microvolt = <1800000>;
  139. regulator-state-mem {
  140. regulator-off-in-suspend;
  141. };
  142. };
  143. // ....
  144. BUCK1 {
  145. regulator-name = "vdd_mif";
  146. regulator-min-microvolt = <800000>;
  147. regulator-max-microvolt = <1300000>;
  148. regulator-always-on;
  149. regulator-boot-on;
  150. regulator-state-mem {
  151. regulator-off-in-suspend;
  152. };
  153. };
  154. BUCK2 {
  155. regulator-name = "vdd_arm";
  156. regulator-min-microvolt = <800000>;
  157. regulator-max-microvolt = <1500000>;
  158. regulator-always-on;
  159. regulator-boot-on;
  160. regulator-coupled-with = <&buck3_reg>;
  161. regulator-coupled-max-spread = <300000>;
  162. regulator-state-mem {
  163. regulator-off-in-suspend;
  164. };
  165. };
  166. BUCK3 {
  167. regulator-name = "vdd_int";
  168. regulator-min-microvolt = <800000>;
  169. regulator-max-microvolt = <1400000>;
  170. regulator-always-on;
  171. regulator-boot-on;
  172. regulator-coupled-with = <&buck2_reg>;
  173. regulator-coupled-max-spread = <300000>;
  174. regulator-state-mem {
  175. regulator-off-in-suspend;
  176. };
  177. };
  178. // ...
  179. };
  180. };
  181. };
  182. - |
  183. #include <dt-bindings/interrupt-controller/irq.h>
  184. i2c {
  185. #address-cells = <1>;
  186. #size-cells = <0>;
  187. pmic@66 {
  188. compatible = "samsung,s2mps14-pmic";
  189. reg = <0x66>;
  190. interrupt-parent = <&gpx0>;
  191. interrupts = <7 IRQ_TYPE_LEVEL_LOW>;
  192. wakeup-source;
  193. clocks {
  194. compatible = "samsung,s2mps14-clk";
  195. #clock-cells = <1>;
  196. clock-output-names = "s2mps14_ap", "unused", "s2mps14_bt";
  197. };
  198. regulators {
  199. LDO1 {
  200. regulator-name = "VLDO1_1.0V";
  201. regulator-min-microvolt = <1000000>;
  202. regulator-max-microvolt = <1000000>;
  203. regulator-always-on;
  204. regulator-state-mem {
  205. regulator-on-in-suspend;
  206. };
  207. };
  208. // ...
  209. BUCK1 {
  210. regulator-name = "VBUCK1_1.0V";
  211. regulator-min-microvolt = <800000>;
  212. regulator-max-microvolt = <1000000>;
  213. regulator-always-on;
  214. regulator-state-mem {
  215. regulator-off-in-suspend;
  216. };
  217. };
  218. // ...
  219. };
  220. };
  221. };