Documentation / devicetree / bindings / mfd / actions,atc260x.yaml


Based on kernel version 6.8. Page generated on 2024-03-11 21:26 EST.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/mfd/actions,atc260x.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Actions Semi ATC260x Power Management IC

maintainers:
  - Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
  - Cristian Ciocaltea <cristian.ciocaltea@gmail.com>

description: |
  ATC260x series PMICs integrates Audio Codec, Power Management, RTC, IR
  and GPIO controller blocks. Currently only the PM related functionalities
  (i.e. regulators and system power-off/reboot) for the ATC2603C and ATC2609A
  chip variants are supported.
  ATC2603C includes 3 programmable DC-DC converters, 9 programmable LDO
  regulators and 1 fixed LDO regulator.
  ATC2609A includes 5 programmable DC-DC converters and 10 programmable LDO
  regulators.

allOf:
  - $ref: ../input/input.yaml

properties:
  compatible:
    enum:
      - actions,atc2603c
      - actions,atc2609a

  reg:
    maxItems: 1

  interrupts:
    maxItems: 1

  reset-time-sec:
    description: |
      Duration in seconds which the key should be kept pressed for device
      to reset automatically. The hardware default is 8. Use 0 to disable
      this functionality.
    enum: [0, 6, 8, 10, 12]

  regulators:
    type: object
    description: |
      List of child nodes specifying the regulators, depending on chip variant:
      * ATC2603C: dcdc[1-3], ldo[1-3,5-8,11,12], switchldo1
      * ATC2609A: dcdc[0-4], ldo[0-9]

    properties:
      compatible:
        enum:
          - actions,atc2603c-regulator
          - actions,atc2609a-regulator

      switchldo1:
        type: object
        $ref: ../regulator/regulator.yaml

        properties:
          regulator-name: true
          regulator-boot-on: true
          regulator-always-on: true
          regulator-min-microvolt: true
          regulator-max-microvolt: true
          regulator-allow-bypass: true
          regulator-active-discharge: true

        additionalProperties: false

    patternProperties:
      "^(dcdc[0-4]|ldo[0-9]|ldo1[1-2]|switchldo1)-supply$":
        description: ATC260x voltage regulators supplies
 
      "^(dcdc[0-4]|ldo[0-9]|ldo1[1-2])$":
        type: object
        $ref: ../regulator/regulator.yaml

        properties:
          regulator-name: true
          regulator-boot-on: true
          regulator-always-on: true
          regulator-min-microvolt: true
          regulator-max-microvolt: true
          regulator-allow-bypass: true

        additionalProperties: false

    allOf:
      - if:
          properties:
            compatible:
              contains:
                const: actions,atc2603c-regulator
        then:
          patternProperties:
            "^(dcdc[0,4]|ldo[0,4,9])(-supply)?$": false
 
            "^(ldo|dcdc)":
              properties:
                regulator-allow-bypass: false
      - if:
          properties:
            compatible:
              contains:
                const: actions,atc2609a-regulator
        then:
          patternProperties:
            "^(ldo1[1-2]|switchldo1)(-supply)?$": false
 
            "^(dcdc|ldo[3-9])":
              properties:
                regulator-allow-bypass: false

    required:
      - compatible

    additionalProperties: false

additionalProperties: false

required:
  - compatible
  - reg
  - interrupts

examples:
  - |
    #include <dt-bindings/interrupt-controller/arm-gic.h>
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;
 
        pmic@65 {
            compatible = "actions,atc2603c";
            reg = <0x65>;
            interrupt-parent = <&sirq>;
            interrupts = <2 IRQ_TYPE_LEVEL_HIGH>;
 
            reset-time-sec = <6>;
 
            regulators {
                compatible = "actions,atc2603c-regulator";
 
                dcdc1-supply = <&reg_5v0>;
                dcdc3-supply = <&reg_5v0>;
                ldo5-supply = <&reg_5v0>;
                switchldo1-supply = <&vcc>;
 
                vdd_cpu: dcdc1 {
                    regulator-name = "VDD_CPU";
                    regulator-min-microvolt = <700000>;
                    regulator-max-microvolt = <1400000>;
                    regulator-always-on;
                };
 
                vcc: dcdc3 {
                    regulator-name = "VCC";
                    regulator-min-microvolt = <2600000>;
                    regulator-max-microvolt = <3300000>;
                    regulator-always-on;
                };
 
                vcc_3v1: ldo5 {
                    regulator-name = "VCC_3V1";
                    regulator-min-microvolt = <2600000>;
                    regulator-max-microvolt = <3300000>;
                };
 
                sd_vcc: switchldo1 {
                    regulator-name = "SD_VCC";
                    regulator-min-microvolt = <3000000>;
                    regulator-max-microvolt = <3300000>;
                    regulator-always-on;
                    regulator-boot-on;
                };
            };
        };
    };

...