11914a996SRob Herring# SPDX-License-Identifier: GPL-2.0 21914a996SRob Herring%YAML 1.2 31914a996SRob Herring--- 41914a996SRob Herring$id: http://devicetree.org/schemas/regulator/regulator.yaml# 51914a996SRob Herring$schema: http://devicetree.org/meta-schemas/core.yaml# 61914a996SRob Herring 71914a996SRob Herringtitle: Voltage/Current Regulators 81914a996SRob Herring 91914a996SRob Herringmaintainers: 101914a996SRob Herring - Liam Girdwood <lgirdwood@gmail.com> 111914a996SRob Herring - Mark Brown <broonie@kernel.org> 121914a996SRob Herring 131914a996SRob Herringproperties: 141914a996SRob Herring regulator-name: 151914a996SRob Herring description: A string used as a descriptive name for regulator outputs 161914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/string" 171914a996SRob Herring 181914a996SRob Herring regulator-min-microvolt: 191914a996SRob Herring description: smallest voltage consumers may set 201914a996SRob Herring 211914a996SRob Herring regulator-max-microvolt: 221914a996SRob Herring description: largest voltage consumers may set 231914a996SRob Herring 241914a996SRob Herring regulator-microvolt-offset: 251914a996SRob Herring description: Offset applied to voltages to compensate for voltage drops 261914a996SRob Herring 271914a996SRob Herring regulator-min-microamp: 281914a996SRob Herring description: smallest current consumers may set 291914a996SRob Herring 301914a996SRob Herring regulator-max-microamp: 311914a996SRob Herring description: largest current consumers may set 321914a996SRob Herring 331914a996SRob Herring regulator-input-current-limit-microamp: 341914a996SRob Herring description: maximum input current regulator allows 351914a996SRob Herring 361914a996SRob Herring regulator-always-on: 371914a996SRob Herring description: boolean, regulator should never be disabled 381914a996SRob Herring type: boolean 391914a996SRob Herring 401914a996SRob Herring regulator-boot-on: 4187fd0db6SDouglas Anderson description: bootloader/firmware enabled regulator. 4287fd0db6SDouglas Anderson It's expected that this regulator was left on by the bootloader. 4387fd0db6SDouglas Anderson If the bootloader didn't leave it on then OS should turn it on 4487fd0db6SDouglas Anderson at boot but shouldn't prevent it from being turned off later. 4587fd0db6SDouglas Anderson This property is intended to only be used for regulators where 4687fd0db6SDouglas Anderson software cannot read the state of the regulator. 471914a996SRob Herring type: boolean 481914a996SRob Herring 491914a996SRob Herring regulator-allow-bypass: 501914a996SRob Herring description: allow the regulator to go into bypass mode 511914a996SRob Herring type: boolean 521914a996SRob Herring 531914a996SRob Herring regulator-allow-set-load: 541914a996SRob Herring description: allow the regulator performance level to be configured 551914a996SRob Herring type: boolean 561914a996SRob Herring 571914a996SRob Herring regulator-ramp-delay: 581914a996SRob Herring description: ramp delay for regulator(in uV/us) For hardware which supports 591914a996SRob Herring disabling ramp rate, it should be explicitly initialised to zero (regulator-ramp-delay 601914a996SRob Herring = <0>) for disabling ramp delay. 611914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 621914a996SRob Herring 631914a996SRob Herring regulator-enable-ramp-delay: 641914a996SRob Herring description: The time taken, in microseconds, for the supply rail to 651914a996SRob Herring reach the target voltage, plus/minus whatever tolerance the board 661914a996SRob Herring design requires. This property describes the total system ramp time 671914a996SRob Herring required due to the combination of internal ramping of the regulator 681914a996SRob Herring itself, and board design issues such as trace capacitance and load 691914a996SRob Herring on the supply. 701914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 711914a996SRob Herring 721914a996SRob Herring regulator-settling-time-us: 731914a996SRob Herring description: Settling time, in microseconds, for voltage change if regulator 741914a996SRob Herring have the constant time for any level voltage change. This is useful 751914a996SRob Herring when regulator have exponential voltage change. 761914a996SRob Herring 771914a996SRob Herring regulator-settling-time-up-us: 781914a996SRob Herring description: Settling time, in microseconds, for voltage increase if 791914a996SRob Herring the regulator needs a constant time to settle after voltage increases 801914a996SRob Herring of any level. This is useful for regulators with exponential voltage 811914a996SRob Herring changes. 821914a996SRob Herring 831914a996SRob Herring regulator-settling-time-down-us: 841914a996SRob Herring description: Settling time, in microseconds, for voltage decrease if 851914a996SRob Herring the regulator needs a constant time to settle after voltage decreases 861914a996SRob Herring of any level. This is useful for regulators with exponential voltage 871914a996SRob Herring changes. 881914a996SRob Herring 891914a996SRob Herring regulator-soft-start: 901914a996SRob Herring description: Enable soft start so that voltage ramps slowly 911914a996SRob Herring type: boolean 921914a996SRob Herring 931914a996SRob Herring regulator-initial-mode: 941914a996SRob Herring description: initial operating mode. The set of possible operating modes 951914a996SRob Herring depends on the capabilities of every hardware so each device binding 961914a996SRob Herring documentation explains which values the regulator supports. 971914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 981914a996SRob Herring 991914a996SRob Herring regulator-allowed-modes: 1001914a996SRob Herring description: list of operating modes that software is allowed to configure 1011914a996SRob Herring for the regulator at run-time. Elements may be specified in any order. 1021914a996SRob Herring The set of possible operating modes depends on the capabilities of 1031914a996SRob Herring every hardware so each device binding document explains which values 1041914a996SRob Herring the regulator supports. 1051914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32-array" 1061914a996SRob Herring 1071914a996SRob Herring regulator-system-load: 1081914a996SRob Herring description: Load in uA present on regulator that is not captured by 1091914a996SRob Herring any consumer request. 1101914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 1111914a996SRob Herring 1121914a996SRob Herring regulator-pull-down: 1131914a996SRob Herring description: Enable pull down resistor when the regulator is disabled. 1141914a996SRob Herring type: boolean 1151914a996SRob Herring 1161914a996SRob Herring regulator-over-current-protection: 1171914a996SRob Herring description: Enable over current protection. 1181914a996SRob Herring type: boolean 1191914a996SRob Herring 1201914a996SRob Herring regulator-active-discharge: 1211914a996SRob Herring description: | 1221914a996SRob Herring tristate, enable/disable active discharge of regulators. The values are: 1231914a996SRob Herring 0: Disable active discharge. 1241914a996SRob Herring 1: Enable active discharge. 1251914a996SRob Herring Absence of this property will leave configuration to default. 1261914a996SRob Herring allOf: 1271914a996SRob Herring - $ref: "/schemas/types.yaml#/definitions/uint32" 1281914a996SRob Herring - enum: [ 0, 1 ] 1291914a996SRob Herring 1301914a996SRob Herring regulator-coupled-with: 1311914a996SRob Herring description: Regulators with which the regulator is coupled. The linkage 1321914a996SRob Herring is 2-way - all coupled regulators should be linked with each other. 1331914a996SRob Herring A regulator should not be coupled with its supplier. 1341914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/phandle-array" 1351914a996SRob Herring 1361914a996SRob Herring regulator-coupled-max-spread: 1371914a996SRob Herring description: Array of maximum spread between voltages of coupled regulators 1381914a996SRob Herring in microvolts, each value in the array relates to the corresponding 1391914a996SRob Herring couple specified by the regulator-coupled-with property. 1401914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 1411914a996SRob Herring 1421914a996SRob Herring regulator-max-step-microvolt: 1431914a996SRob Herring description: Maximum difference between current and target voltages 1441914a996SRob Herring that can be changed safely in a single step. 1451914a996SRob Herring 1461914a996SRob HerringpatternProperties: 1471914a996SRob Herring ".*-supply$": 1481914a996SRob Herring description: Input supply phandle(s) for this node 1491914a996SRob Herring 1501914a996SRob Herring regulator-state-(standby|mem|disk): 1511914a996SRob Herring type: object 1521914a996SRob Herring description: 1531914a996SRob Herring sub-nodes for regulator state in Standby, Suspend-to-RAM, and 1541914a996SRob Herring Suspend-to-DISK modes. Equivalent with standby, mem, and disk Linux 1551914a996SRob Herring sleep states. 1561914a996SRob Herring 1571914a996SRob Herring properties: 1581914a996SRob Herring regulator-on-in-suspend: 1591914a996SRob Herring description: regulator should be on in suspend state. 1601914a996SRob Herring type: boolean 1611914a996SRob Herring 1621914a996SRob Herring regulator-off-in-suspend: 1631914a996SRob Herring description: regulator should be off in suspend state. 1641914a996SRob Herring type: boolean 1651914a996SRob Herring 1661914a996SRob Herring regulator-suspend-min-microvolt: 1671914a996SRob Herring description: minimum voltage may be set in suspend state. 1681914a996SRob Herring 1691914a996SRob Herring regulator-suspend-max-microvolt: 1701914a996SRob Herring description: maximum voltage may be set in suspend state. 1711914a996SRob Herring 1721914a996SRob Herring regulator-suspend-microvolt: 1731914a996SRob Herring description: the default voltage which regulator would be set in 1741914a996SRob Herring suspend. This property is now deprecated, instead setting voltage 1751914a996SRob Herring for suspend mode via the API which regulator driver provides is 1761914a996SRob Herring recommended. 1771914a996SRob Herring 1781914a996SRob Herring regulator-changeable-in-suspend: 1791914a996SRob Herring description: whether the default voltage and the regulator on/off 1801914a996SRob Herring in suspend can be changed in runtime. 1811914a996SRob Herring type: boolean 1821914a996SRob Herring 1831914a996SRob Herring regulator-mode: 1841914a996SRob Herring description: operating mode in the given suspend state. The set 1851914a996SRob Herring of possible operating modes depends on the capabilities of every 1861914a996SRob Herring hardware so the valid modes are documented on each regulator device 1871914a996SRob Herring tree binding document. 1881914a996SRob Herring $ref: "/schemas/types.yaml#/definitions/uint32" 1891914a996SRob Herring 1901914a996SRob Herring additionalProperties: false 1911914a996SRob Herring 1921914a996SRob Herringexamples: 1931914a996SRob Herring - | 194*51a21e0eSRob Herring xyzreg: regulator { 1951914a996SRob Herring regulator-min-microvolt = <1000000>; 1961914a996SRob Herring regulator-max-microvolt = <2500000>; 1971914a996SRob Herring regulator-always-on; 1981914a996SRob Herring vin-supply = <&vin>; 1991914a996SRob Herring 2001914a996SRob Herring regulator-state-mem { 2011914a996SRob Herring regulator-on-in-suspend; 2021914a996SRob Herring }; 2031914a996SRob Herring }; 2041914a996SRob Herring 2051914a996SRob Herring... 206