rpm-regulator-smd.txt 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223
  1. Qualcomm RPM Regulators
  2. rpm-regulator-smd is a regulator driver which supports regulators inside of
  3. PMICs which are controlled by the RPM processor. Communication with the RPM
  4. processor takes place over SMD.
  5. Required structure:
  6. - RPM regulators must be described in two levels of devices nodes. The first
  7. level describes the interface with the RPM. The second level describes
  8. properties of one regulator framework interface (of potentially many) to
  9. the regulator.
  10. [First Level Nodes]
  11. Required properties:
  12. - compatible: Must be "qcom,rpm-regulator-smd-resource"
  13. - qcom,resource-name: Resource name string for this regulator to be used in RPM
  14. transactions. Length is 4 characters max.
  15. - qcom,resource-id: Resource instance ID for this regulator to be used in RPM
  16. transactions.
  17. - qcom,regulator-type: Type of this regulator. Supported values are:
  18. 0 = LDO
  19. 1 = SMPS
  20. 2 = VS
  21. 3 = NCP
  22. Optional properties:
  23. - qcom,allow-atomic: Flag specifying if atomic access is allowed for this
  24. regulator. Supported values are:
  25. 0 or not present = mutex locks used
  26. 1 = spinlocks used
  27. - qcom,enable-time: Time in us to delay after enabling the regulator
  28. - qcom,hpm-min-load: Load current in uA which corresponds to the minimum load
  29. which requires the regulator to be in high power mode.
  30. - qcom,apps-only: Flag which indicates that the regulator only has
  31. consumers on the application processor. If this flag
  32. is specified, then voltage and current updates are
  33. only sent to the RPM if the regulator is enabled.
  34. [Second Level Nodes]
  35. Required properties:
  36. - compatible: Must be "qcom,rpm-regulator-smd"
  37. - regulator-name: A string used as a descriptive name for regulator outputs
  38. - qcom,set: Specifies which sets that requests made with this
  39. regulator interface should be sent to. Regulator
  40. requests sent in the active set take effect immediately.
  41. Requests sent in the sleep set take effect when the Apps
  42. processor transitions into RPM assisted power collapse.
  43. Supported values are:
  44. 1 = Active set only
  45. 2 = Sleep set only
  46. 3 = Both active and sleep sets
  47. Optional properties:
  48. - parent-supply: phandle to the parent supply/regulator node
  49. - qcom,system-load: Load in uA present on regulator that is not
  50. captured by any consumer request
  51. - qcom,use-voltage-corner: Flag that signifies if regulator_set_voltage
  52. calls should modify the corner parameter instead
  53. of the voltage parameter. When used, voltages
  54. specified inside of the regulator framework
  55. represent corners that have been incremented by
  56. 1. This value shift is necessary to work around
  57. limitations in the regulator framework which
  58. treat 0 uV as an error.
  59. - qcom,use-voltage-floor-corner: Flag that signifies if regulator_set_voltage
  60. calls should modify the floor corner parameter
  61. instead of the voltage parameter. When used,
  62. voltages specified inside of the regulator
  63. framework represent corners that have been
  64. incremented by 1. The properties
  65. qcom,use-voltage-corner and
  66. qcom,use-voltage-floor-corner are mutually
  67. exclusive. Only one may be specified for a
  68. given regulator.
  69. - qcom,always-send-voltage: Flag which indicates that updates to the voltage
  70. or voltage corner set point should always be
  71. sent immediately to the RPM. If this flag is
  72. not specified, then voltage set point updates
  73. are only sent if the given regulator has also
  74. been enabled by a Linux consumer.
  75. - qcom,always-send-current: Flag which indicates that updates to the load
  76. current should always be sent immediately to the
  77. RPM. If this flag is not specified, then load
  78. current updates are only sent if the given
  79. regulator has also been enabled by a Linux
  80. consumer.
  81. The following properties specify initial values for parameters to be sent to the
  82. RPM in regulator requests.
  83. - qcom,init-enable: 0 = regulator disabled
  84. 1 = regulator enabled
  85. - qcom,init-voltage: Voltage in uV
  86. - qcom,init-current: Current in mA
  87. - qcom,init-ldo-mode: Operating mode to be used with LDO regulators
  88. Supported values are:
  89. 0 = mode determined by current requests
  90. 1 = force HPM (NPM)
  91. - qcom,init-smps-mode: Operating mode to be used with SMPS regulators
  92. Supported values are:
  93. 0 = auto; hardware determines mode
  94. 1 = mode determined by current requests
  95. 2 = force HPM (PWM)
  96. - qcom,init-pin-ctrl-enable: Bit mask specifying which hardware pins should be
  97. used to enable the regulator, if any; supported
  98. bits are:
  99. 0 = ignore all hardware enable signals
  100. BIT(0) = follow HW0_EN signal
  101. BIT(1) = follow HW1_EN signal
  102. BIT(2) = follow HW2_EN signal
  103. BIT(3) = follow HW3_EN signal
  104. - qcom,init-pin-ctrl-mode: Bit mask specifying which hardware pins should be
  105. used to force the regulator into high power
  106. mode, if any. Supported bits are:
  107. 0 = ignore all hardware enable signals
  108. BIT(0) = follow HW0_EN signal
  109. BIT(1) = follow HW1_EN signal
  110. BIT(2) = follow HW2_EN signal
  111. BIT(3) = follow HW3_EN signal
  112. BIT(4) = follow PMIC awake state
  113. - qcom,init-frequency: Switching frequency divisor for SMPS regulators.
  114. Supported values are n = 0 to 31 where
  115. freq = 19.2 MHz / (n + 1).
  116. - qcom,init-head-room: Voltage head room in mV required for the
  117. regulator. This head room value should be used
  118. in situations where the device connected to the
  119. output of the regulator has low noise tolerance.
  120. Note that the RPM independently enforces a
  121. safety head room value for subregulated LDOs
  122. which is sufficient to account for LDO drop-out
  123. voltage.
  124. - qcom,init-quiet-mode: Specify that quiet mode is needed for an SMPS
  125. regulator in order to have lower output noise.
  126. Supported values are:
  127. 0 = No quiet mode
  128. 1 = Quiet mode
  129. 2 = Super quiet mode
  130. - qcom,init-freq-reason: Consumer requiring specified frequency for an
  131. SMPS regulator. Supported values are:
  132. 0 = None
  133. 1 = Bluetooth
  134. 2 = GPS
  135. 4 = WLAN
  136. 8 = WAN
  137. - qcom,init-voltage-corner: Performance corner to use in order to determine
  138. voltage set point. This value corresponds to
  139. the actual value that will be sent and is not
  140. incremented by 1 like the values used inside of
  141. the regulator framework. The meaning of corner
  142. values is set by the RPM. It is possible that
  143. different regulators on a given platform or
  144. similar regulators on different platforms will
  145. utilize different corner values. These are
  146. corner values supported on MSM8974 for PMIC
  147. PM8841 SMPS 2 (VDD_Dig); nominal voltages for
  148. these corners are also shown:
  149. 0 = None (don't care)
  150. 1 = Retention (0.5000 V)
  151. 2 = SVS Krait (0.7250 V)
  152. 3 = SVS SOC (0.8125 V)
  153. 4 = Normal (0.9000 V)
  154. 5 = Turbo (0.9875 V)
  155. 6 = Super Turbo (1.0500 V)
  156. - qcom,init-disallow-bypass: Specify that bypass mode should not be used for a
  157. given LDO regulator. When in bypass mode, an
  158. LDO performs no regulation and acts as a simple
  159. switch. The RPM can utilize this mode for an
  160. LDO that is subregulated from an SMPS when it is
  161. possible to reduce the SMPS voltage to the
  162. desired LDO output level. Bypass mode may be
  163. disallowed if lower LDO output noise is
  164. required. Supported values are:
  165. 0 = Allow RPM to utilize LDO bypass mode
  166. if possible
  167. 1 = Disallow LDO bypass mode
  168. - qcom,init-voltage-floor-corner: Minimum performance corner to use if any
  169. processor in the system is awake. This property
  170. supports the same values as
  171. qcom,init-voltage-corner.
  172. All properties specified within the core regulator framework can also be used in
  173. second level nodes. These bindings can be found in:
  174. Documentation/devicetree/bindings/regulator/regulator.txt.
  175. Example:
  176. rpm-regulator-smpb1 {
  177. qcom,resource-name = "smpb";
  178. qcom,resource-id = <1>;
  179. qcom,regulator-type = <1>;
  180. qcom,hpm-min-load = <100000>;
  181. compatible = "qcom,rpm-regulator-smd-resource";
  182. status = "disabled";
  183. pm8841_s1: regulator-s1 {
  184. regulator-name = "8841_s1";
  185. qcom,set = <3>;
  186. regulator-min-microvolt = <900000>;
  187. regulator-max-microvolt = <1150000>;
  188. qcom,init-voltage = <1150000>;
  189. compatible = "qcom,rpm-regulator-smd";
  190. };
  191. pm8841_s1_ao: regulator-s1-ao {
  192. regulator-name = "8841_s1_ao";
  193. qcom,set = <1>;
  194. regulator-min-microvolt = <900000>;
  195. regulator-max-microvolt = <1150000>;
  196. compatible = "qcom,rpm-regulator-smd";
  197. };
  198. pm8841_s1_corner: regulator-s1-corner {
  199. regulator-name = "8841_s1_corner";
  200. qcom,set = <3>;
  201. regulator-min-microvolt = <1>;
  202. regulator-max-microvolt = <6>;
  203. qcom,init-voltage-corner = <3>;
  204. qcom,use-voltage-corner;
  205. compatible = "qcom,rpm-regulator-smd";
  206. };
  207. };