18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
28c2ecf20Sopenharmony_ci%YAML 1.2
38c2ecf20Sopenharmony_ci---
48c2ecf20Sopenharmony_ci$id: http://devicetree.org/schemas/regulator/rohm,bd71847-regulator.yaml#
58c2ecf20Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml#
68c2ecf20Sopenharmony_ci
78c2ecf20Sopenharmony_cititle: ROHM BD71847 and BD71850 Power Management Integrated Circuit regulators
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_cimaintainers:
108c2ecf20Sopenharmony_ci  - Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
118c2ecf20Sopenharmony_ci
128c2ecf20Sopenharmony_cidescription: |
138c2ecf20Sopenharmony_ci  List of regulators provided by this controller. BD71847 regulators node
148c2ecf20Sopenharmony_ci  should be sub node of the BD71847 MFD node. See BD71847 MFD bindings at
158c2ecf20Sopenharmony_ci  Documentation/devicetree/bindings/mfd/rohm,bd71847-pmic.yaml
168c2ecf20Sopenharmony_ci  Regulator nodes should be named to BUCK_<number> and LDO_<number>. The
178c2ecf20Sopenharmony_ci  definition for each of these nodes is defined using the standard
188c2ecf20Sopenharmony_ci  binding for regulators at
198c2ecf20Sopenharmony_ci  Documentation/devicetree/bindings/regulator/regulator.txt.
208c2ecf20Sopenharmony_ci  Note that if BD71847 starts at RUN state you probably want to use
218c2ecf20Sopenharmony_ci  regulator-boot-on at least for BUCK5. LDO6 is supplied by it and it must
228c2ecf20Sopenharmony_ci  not be disabled by driver at startup. If BUCK5 is disabled at startup the
238c2ecf20Sopenharmony_ci  voltage monitoring for LDO5/LDO6 can cause PMIC to reset.
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci#The valid names for BD71847 regulator nodes are:
268c2ecf20Sopenharmony_ci#BUCK1, BUCK2, BUCK3, BUCK4, BUCK5, BUCK6
278c2ecf20Sopenharmony_ci#LDO1, LDO2, LDO3, LDO4, LDO5, LDO6
288c2ecf20Sopenharmony_ci
298c2ecf20Sopenharmony_cipatternProperties:
308c2ecf20Sopenharmony_ci  "^LDO[1-6]$":
318c2ecf20Sopenharmony_ci    type: object
328c2ecf20Sopenharmony_ci    $ref: regulator.yaml#
338c2ecf20Sopenharmony_ci    description:
348c2ecf20Sopenharmony_ci      Properties for single LDO regulator.
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ci    properties:
378c2ecf20Sopenharmony_ci      regulator-name:
388c2ecf20Sopenharmony_ci        pattern: "^ldo[1-6]$"
398c2ecf20Sopenharmony_ci        description:
408c2ecf20Sopenharmony_ci          should be "ldo1", ..., "ldo6"
418c2ecf20Sopenharmony_ci
428c2ecf20Sopenharmony_ci    unevaluatedProperties: false
438c2ecf20Sopenharmony_ci
448c2ecf20Sopenharmony_ci  "^BUCK[1-6]$":
458c2ecf20Sopenharmony_ci    type: object
468c2ecf20Sopenharmony_ci    $ref: regulator.yaml#
478c2ecf20Sopenharmony_ci    description:
488c2ecf20Sopenharmony_ci      Properties for single BUCK regulator.
498c2ecf20Sopenharmony_ci
508c2ecf20Sopenharmony_ci    properties:
518c2ecf20Sopenharmony_ci      regulator-name:
528c2ecf20Sopenharmony_ci        pattern: "^buck[1-6]$"
538c2ecf20Sopenharmony_ci        description:
548c2ecf20Sopenharmony_ci          should be "buck1", ..., "buck6"
558c2ecf20Sopenharmony_ci
568c2ecf20Sopenharmony_ci      rohm,dvs-run-voltage:
578c2ecf20Sopenharmony_ci        $ref: "/schemas/types.yaml#/definitions/uint32"
588c2ecf20Sopenharmony_ci        minimum: 0
598c2ecf20Sopenharmony_ci        maximum: 1300000
608c2ecf20Sopenharmony_ci        description:
618c2ecf20Sopenharmony_ci          PMIC default "RUN" state voltage in uV. See below table for
628c2ecf20Sopenharmony_ci          bucks which support this. 0 means disabled.
638c2ecf20Sopenharmony_ci
648c2ecf20Sopenharmony_ci      rohm,dvs-idle-voltage:
658c2ecf20Sopenharmony_ci        $ref: "/schemas/types.yaml#/definitions/uint32"
668c2ecf20Sopenharmony_ci        minimum: 0
678c2ecf20Sopenharmony_ci        maximum: 1300000
688c2ecf20Sopenharmony_ci        description:
698c2ecf20Sopenharmony_ci          PMIC default "IDLE" state voltage in uV. See below table for
708c2ecf20Sopenharmony_ci          bucks which support this. 0 means disabled.
718c2ecf20Sopenharmony_ci
728c2ecf20Sopenharmony_ci      rohm,dvs-suspend-voltage:
738c2ecf20Sopenharmony_ci        $ref: "/schemas/types.yaml#/definitions/uint32"
748c2ecf20Sopenharmony_ci        minimum: 0
758c2ecf20Sopenharmony_ci        maximum: 1300000
768c2ecf20Sopenharmony_ci        description:
778c2ecf20Sopenharmony_ci          PMIC default "SUSPEND" state voltage in uV. See below table for
788c2ecf20Sopenharmony_ci          bucks which support this. 0 means disabled.
798c2ecf20Sopenharmony_ci
808c2ecf20Sopenharmony_ci        # Supported default DVS states:
818c2ecf20Sopenharmony_ci        #
828c2ecf20Sopenharmony_ci        # BD71847:
838c2ecf20Sopenharmony_ci        # buck | dvs-run-voltage | dvs-idle-voltage | dvs-suspend-voltage
848c2ecf20Sopenharmony_ci        # ----------------------------------------------------------------
858c2ecf20Sopenharmony_ci        # 1    | supported       | supported        | supported
868c2ecf20Sopenharmony_ci        # ----------------------------------------------------------------
878c2ecf20Sopenharmony_ci        # 2    | supported       | supported        | not supported
888c2ecf20Sopenharmony_ci        # ----------------------------------------------------------------
898c2ecf20Sopenharmony_ci        # rest | not supported   | not supported    | not supported
908c2ecf20Sopenharmony_ci
918c2ecf20Sopenharmony_ci      # BD718(47/50) power outputs can either be controlled by the PMIC internal
928c2ecf20Sopenharmony_ci      # hardware state machine or by software. If you need regulators to be
938c2ecf20Sopenharmony_ci      # turned ON/OFF for example based on PMIC_STBY_REQ line (which toggles
948c2ecf20Sopenharmony_ci      # PMIC HW state machine) - then you should set this property.
958c2ecf20Sopenharmony_ci      # Tradeoff is that then SW can't control the ON/OFF state for this
968c2ecf20Sopenharmony_ci      # regulator (other than invoking a PMIC state change).
978c2ecf20Sopenharmony_ci      rohm,no-regulator-enable-control:
988c2ecf20Sopenharmony_ci        description: |
998c2ecf20Sopenharmony_ci          Enable/Disable control of this regulator must be left to the
1008c2ecf20Sopenharmony_ci          PMIC hardware state machine.
1018c2ecf20Sopenharmony_ci        type: boolean
1028c2ecf20Sopenharmony_ci    required:
1038c2ecf20Sopenharmony_ci      - regulator-name
1048c2ecf20Sopenharmony_ci
1058c2ecf20Sopenharmony_ci    unevaluatedProperties: false
1068c2ecf20Sopenharmony_ci
1078c2ecf20Sopenharmony_ciadditionalProperties: false
108