162306a36Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 262306a36Sopenharmony_ci%YAML 1.2 362306a36Sopenharmony_ci--- 462306a36Sopenharmony_ci$id: http://devicetree.org/schemas/regulator/rohm,bd71837-regulator.yaml# 562306a36Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml# 662306a36Sopenharmony_ci 762306a36Sopenharmony_cititle: ROHM BD71837 Power Management Integrated Circuit regulators 862306a36Sopenharmony_ci 962306a36Sopenharmony_cimaintainers: 1062306a36Sopenharmony_ci - Matti Vaittinen <mazziesaccount@gmail.com> 1162306a36Sopenharmony_ci 1262306a36Sopenharmony_cidescription: | 1362306a36Sopenharmony_ci List of regulators provided by this controller. BD71837 regulators node 1462306a36Sopenharmony_ci should be sub node of the BD71837 MFD node. See BD71837 MFD bindings at 1562306a36Sopenharmony_ci Documentation/devicetree/bindings/mfd/rohm,bd71837-pmic.yaml 1662306a36Sopenharmony_ci Regulator nodes should be named to BUCK_<number> and LDO_<number>. The 1762306a36Sopenharmony_ci definition for each of these nodes is defined using the standard 1862306a36Sopenharmony_ci binding for regulators at 1962306a36Sopenharmony_ci Documentation/devicetree/bindings/regulator/regulator.txt. 2062306a36Sopenharmony_ci Note that if BD71837 starts at RUN state you probably want to use 2162306a36Sopenharmony_ci regulator-boot-on at least for BUCK6 and BUCK7 so that those are not 2262306a36Sopenharmony_ci disabled by driver at startup. LDO5 and LDO6 are supplied by those and 2362306a36Sopenharmony_ci if they are disabled at startup the voltage monitoring for LDO5/LDO6 will 2462306a36Sopenharmony_ci cause PMIC to reset. 2562306a36Sopenharmony_ci 2662306a36Sopenharmony_ci# The valid names for BD71837 regulator nodes are: 2762306a36Sopenharmony_ci# BUCK1, BUCK2, BUCK3, BUCK4, BUCK5, BUCK6, BUCK7, BUCK8 2862306a36Sopenharmony_ci# LDO1, LDO2, LDO3, LDO4, LDO5, LDO6, LDO7 2962306a36Sopenharmony_ci 3062306a36Sopenharmony_cipatternProperties: 3162306a36Sopenharmony_ci "^LDO[1-7]$": 3262306a36Sopenharmony_ci type: object 3362306a36Sopenharmony_ci $ref: regulator.yaml# 3462306a36Sopenharmony_ci description: 3562306a36Sopenharmony_ci Properties for single LDO regulator. 3662306a36Sopenharmony_ci 3762306a36Sopenharmony_ci properties: 3862306a36Sopenharmony_ci regulator-name: 3962306a36Sopenharmony_ci pattern: "^ldo[1-7]$" 4062306a36Sopenharmony_ci description: 4162306a36Sopenharmony_ci should be "ldo1", ..., "ldo7" 4262306a36Sopenharmony_ci 4362306a36Sopenharmony_ci unevaluatedProperties: false 4462306a36Sopenharmony_ci 4562306a36Sopenharmony_ci "^BUCK[1-8]$": 4662306a36Sopenharmony_ci type: object 4762306a36Sopenharmony_ci $ref: regulator.yaml# 4862306a36Sopenharmony_ci description: 4962306a36Sopenharmony_ci Properties for single BUCK regulator. 5062306a36Sopenharmony_ci 5162306a36Sopenharmony_ci properties: 5262306a36Sopenharmony_ci regulator-name: 5362306a36Sopenharmony_ci pattern: "^buck[1-8]$" 5462306a36Sopenharmony_ci description: 5562306a36Sopenharmony_ci should be "buck1", ..., "buck8" 5662306a36Sopenharmony_ci 5762306a36Sopenharmony_ci rohm,dvs-run-voltage: 5862306a36Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 5962306a36Sopenharmony_ci minimum: 0 6062306a36Sopenharmony_ci maximum: 1300000 6162306a36Sopenharmony_ci description: 6262306a36Sopenharmony_ci PMIC default "RUN" state voltage in uV. See below table for 6362306a36Sopenharmony_ci bucks which support this. 0 means disabled. 6462306a36Sopenharmony_ci 6562306a36Sopenharmony_ci rohm,dvs-idle-voltage: 6662306a36Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 6762306a36Sopenharmony_ci minimum: 0 6862306a36Sopenharmony_ci maximum: 1300000 6962306a36Sopenharmony_ci description: 7062306a36Sopenharmony_ci PMIC default "IDLE" state voltage in uV. See below table for 7162306a36Sopenharmony_ci bucks which support this. 0 means disabled. 7262306a36Sopenharmony_ci 7362306a36Sopenharmony_ci rohm,dvs-suspend-voltage: 7462306a36Sopenharmony_ci $ref: /schemas/types.yaml#/definitions/uint32 7562306a36Sopenharmony_ci minimum: 0 7662306a36Sopenharmony_ci maximum: 1300000 7762306a36Sopenharmony_ci description: 7862306a36Sopenharmony_ci PMIC default "SUSPEND" state voltage in uV. See below table for 7962306a36Sopenharmony_ci bucks which support this. 0 means disabled. 8062306a36Sopenharmony_ci 8162306a36Sopenharmony_ci # Supported default DVS states: 8262306a36Sopenharmony_ci # 8362306a36Sopenharmony_ci # BD71837: 8462306a36Sopenharmony_ci # buck | dvs-run-voltage | dvs-idle-voltage | dvs-suspend-voltage 8562306a36Sopenharmony_ci # ---------------------------------------------------------------- 8662306a36Sopenharmony_ci # 1 | supported | supported | supported 8762306a36Sopenharmony_ci # ---------------------------------------------------------------- 8862306a36Sopenharmony_ci # 2 | supported | supported | not supported 8962306a36Sopenharmony_ci # ---------------------------------------------------------------- 9062306a36Sopenharmony_ci # 3 | supported | not supported | not supported 9162306a36Sopenharmony_ci # ---------------------------------------------------------------- 9262306a36Sopenharmony_ci # 4 | supported | not supported | not supported 9362306a36Sopenharmony_ci # ---------------------------------------------------------------- 9462306a36Sopenharmony_ci # rest | not supported | not supported | not supported 9562306a36Sopenharmony_ci 9662306a36Sopenharmony_ci # BD71837 power outputs can either be controlled by the PMIC internal 9762306a36Sopenharmony_ci # hardware state machine or by software. If you need regulators to be 9862306a36Sopenharmony_ci # turned ON/OFF for example based on PMIC_STBY_REQ line (which toggles 9962306a36Sopenharmony_ci # PMIC HW state machine) - then you should set this property. 10062306a36Sopenharmony_ci # Tradeoff is that then SW can't control the ON/OFF state for this 10162306a36Sopenharmony_ci # regulator (other than invoking a PMIC state change). 10262306a36Sopenharmony_ci rohm,no-regulator-enable-control: 10362306a36Sopenharmony_ci description: | 10462306a36Sopenharmony_ci Enable/Disable control of this regulator must be left to the 10562306a36Sopenharmony_ci PMIC hardware state machine. 10662306a36Sopenharmony_ci type: boolean 10762306a36Sopenharmony_ci 10862306a36Sopenharmony_ci # Setups where regulator (especially the buck8) output voltage is scaled 10962306a36Sopenharmony_ci # by adding external connection where some other regulator output is 11062306a36Sopenharmony_ci # connected to feedback-pin (over suitable resistors) is getting popular 11162306a36Sopenharmony_ci # amongst users of BD71837. (This allows for example scaling down the 11262306a36Sopenharmony_ci # buck8 voltages to suit lover GPU voltages for projects where buck8 is 11362306a36Sopenharmony_ci # (ab)used to supply power for GPU. 11462306a36Sopenharmony_ci # 11562306a36Sopenharmony_ci # So we allow describing this external connection from DT and scale the 11662306a36Sopenharmony_ci # voltages accordingly. This is what the connection should look like: 11762306a36Sopenharmony_ci # 11862306a36Sopenharmony_ci # |---------------| 11962306a36Sopenharmony_ci # | buck 8 |-------+----->Vout 12062306a36Sopenharmony_ci # | | | 12162306a36Sopenharmony_ci # |---------------| | 12262306a36Sopenharmony_ci # | | 12362306a36Sopenharmony_ci # | | 12462306a36Sopenharmony_ci # +-------+--R2----+ 12562306a36Sopenharmony_ci # | 12662306a36Sopenharmony_ci # R1 12762306a36Sopenharmony_ci # | 12862306a36Sopenharmony_ci # V FB-pull-up 12962306a36Sopenharmony_ci # 13062306a36Sopenharmony_ci # Here the buck output is sifted according to formula: 13162306a36Sopenharmony_ci # 13262306a36Sopenharmony_ci # Vout_o = Vo - (Vpu - Vo)*R2/R1 13362306a36Sopenharmony_ci # Linear_step = step_orig*(R1+R2)/R1 13462306a36Sopenharmony_ci # 13562306a36Sopenharmony_ci # where: 13662306a36Sopenharmony_ci # Vout_o is adjusted voltage output at vsel reg value 0 13762306a36Sopenharmony_ci # Vo is original voltage output at vsel reg value 0 13862306a36Sopenharmony_ci # Vpu is the pull-up voltage V FB-pull-up in the picture 13962306a36Sopenharmony_ci # R1 and R2 are resistor values. 14062306a36Sopenharmony_ci 14162306a36Sopenharmony_ci rohm,fb-pull-up-microvolt: 14262306a36Sopenharmony_ci description: 14362306a36Sopenharmony_ci Feedback-pin has pull-up connection to adjust voltage range. This is 14462306a36Sopenharmony_ci the used pull-up voltage before R1. 14562306a36Sopenharmony_ci 14662306a36Sopenharmony_ci rohm,feedback-pull-up-r1-ohms: 14762306a36Sopenharmony_ci description: 14862306a36Sopenharmony_ci Feedback-pin has pull-up connection to adjust voltage range. This is 14962306a36Sopenharmony_ci the used R1 resistor. 15062306a36Sopenharmony_ci 15162306a36Sopenharmony_ci rohm,feedback-pull-up-r2-ohms: 15262306a36Sopenharmony_ci description: 15362306a36Sopenharmony_ci Feedback-pin has pull-up connection to adjust voltage range. This is 15462306a36Sopenharmony_ci the used R2 resistor. 15562306a36Sopenharmony_ci 15662306a36Sopenharmony_ci required: 15762306a36Sopenharmony_ci - regulator-name 15862306a36Sopenharmony_ci 15962306a36Sopenharmony_ci unevaluatedProperties: false 16062306a36Sopenharmony_ci 16162306a36Sopenharmony_ciadditionalProperties: false 162