Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 1 | # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) |
| 2 | %YAML 1.2 |
| 3 | --- |
| 4 | $id: http://devicetree.org/schemas/regulator/dlg,da9121.yaml# |
| 5 | $schema: http://devicetree.org/meta-schemas/core.yaml# |
| 6 | |
| 7 | title: Dialog Semiconductor DA9121 voltage regulator |
| 8 | |
| 9 | maintainers: |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 10 | - Adam Ward <Adam.Ward.opensource@diasemi.com> |
| 11 | |
| 12 | description: | |
| 13 | Dialog Semiconductor DA9121 Single-channel 10A double-phase buck converter |
| 14 | Dialog Semiconductor DA9122 Double-channel 5A single-phase buck converter |
| 15 | Dialog Semiconductor DA9220 Double-channel 3A single-phase buck converter |
| 16 | Dialog Semiconductor DA9217 Single-channel 6A double-phase buck converter |
| 17 | Dialog Semiconductor DA9130 Single-channel 10A double-phase buck converter |
| 18 | Dialog Semiconductor DA9131 Double-channel 5A single-phase buck converter |
| 19 | Dialog Semiconductor DA9132 Double-channel 3A single-phase buck converter |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 20 | Dialog Semiconductor DA9141 Single-channel 40A quad-phase buck converter |
| 21 | Dialog Semiconductor DA9142 Single-channel 20A double-phase buck converter |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 22 | |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 23 | Device parameter ranges |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 24 | |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 25 | The current limits can be set to at/near double the rated current per channel |
| 26 | to allow for transient peaks. |
| 27 | Current limit changes when the output is enabled are not supported, as a |
| 28 | precaution against undefined behaviour. |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 29 | |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 30 | |----------------------------------------------| |
| 31 | | | range & reset default value | |
| 32 | | Device |------------------------------| |
| 33 | | | microvolt | microamp | |
| 34 | |----------------------------------------------| |
| 35 | | DA9121/DA9130 | Min: 300000 | Min: 7000000 | |
| 36 | | | Max: 1900000 | Max: 20000000 | |
| 37 | |----------------------------------------------| |
| 38 | | DA9121/DA9131 | Min: 300000 | Min: 3500000 | |
| 39 | | | Max: 1900000 | Max: 10000000 | |
| 40 | |----------------------------------------------| |
| 41 | | DA9121/DA9131 | Min: 300000 | Min: 3500000 | |
| 42 | | | Max: 1900000 | Max: 6000000 | |
| 43 | |----------------------------------------------| |
| 44 | | DA9217 | Min: 300000 | Min: 7000000 | |
| 45 | | | Max: 1900000 | Max: 12000000 | |
| 46 | |----------------------------------------------| |
| 47 | | DA9141 | Min: 300000 | Min: 26000000 | |
| 48 | | | Max: 1300000 | Max: 78000000 | |
| 49 | |----------------------------------------------| |
| 50 | | DA9142 | Min: 300000 | Min: 13000000 | |
| 51 | | | Max: 1300000 | Max: 39000000 | |
| 52 | |----------------------------------------------| |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 53 | |
| 54 | properties: |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 55 | $nodename: |
| 56 | pattern: "pmic@[0-9a-f]{1,2}" |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 57 | compatible: |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 58 | enum: |
| 59 | - dlg,da9121 |
| 60 | - dlg,da9122 |
| 61 | - dlg,da9220 |
| 62 | - dlg,da9217 |
| 63 | - dlg,da9130 |
| 64 | - dlg,da9131 |
| 65 | - dlg,da9132 |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 66 | - dlg,da9141 |
| 67 | - dlg,da9142 |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 68 | |
| 69 | reg: |
| 70 | maxItems: 1 |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 71 | description: Specifies the I2C slave address. |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 72 | |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 73 | interrupts: |
| 74 | maxItems: 1 |
| 75 | description: IRQ line information. |
| 76 | |
| 77 | dlg,irq-polling-delay-passive-ms: |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 78 | minimum: 1000 |
| 79 | maximum: 10000 |
| 80 | description: | |
| 81 | Specify the polling period, measured in milliseconds, between interrupt status |
| 82 | update checks. Range 1000-10000 ms. |
| 83 | |
| 84 | regulators: |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 85 | type: object |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 86 | description: | |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 87 | List of regulators provided by the device |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 88 | |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 89 | patternProperties: |
| 90 | "^buck([1-2])$": |
| 91 | type: object |
| 92 | $ref: regulator.yaml# |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 93 | description: | |
| 94 | Properties for a single BUCK regulator |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 95 | |
| 96 | properties: |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 97 | regulator-name: |
| 98 | pattern: "^BUCK([1-2])$" |
| 99 | description: | |
| 100 | BUCK2 present in DA9122, DA9220, DA9131, DA9132 only |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 101 | |
| 102 | regulator-initial-mode: |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 103 | enum: [ 0, 1, 2, 3 ] |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 104 | description: Defined in include/dt-bindings/regulator/dlg,da9121-regulator.h |
| 105 | |
| 106 | enable-gpios: |
| 107 | maxItems: 1 |
| 108 | description: Specify a valid GPIO for platform control of the regulator |
| 109 | |
| 110 | dlg,ripple-cancel: |
| 111 | $ref: "/schemas/types.yaml#/definitions/uint32" |
Adam Ward | d07fef2 | 2021-11-29 22:10:11 +0000 | [diff] [blame] | 112 | enum: [ 0, 1, 2, 3 ] |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 113 | description: | |
| 114 | Defined in include/dt-bindings/regulator/dlg,da9121-regulator.h |
| 115 | Only present on multi-channel devices (DA9122, DA9220, DA9131, DA9132) |
| 116 | |
| 117 | unevaluatedProperties: false |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 118 | |
| 119 | required: |
| 120 | - compatible |
| 121 | - reg |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 122 | - regulators |
| 123 | |
| 124 | additionalProperties: false |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 125 | |
| 126 | examples: |
| 127 | - | |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 128 | #include <dt-bindings/gpio/gpio.h> |
| 129 | #include <dt-bindings/interrupt-controller/irq.h> |
| 130 | #include <dt-bindings/regulator/dlg,da9121-regulator.h> |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 131 | i2c { |
| 132 | #address-cells = <1>; |
| 133 | #size-cells = <0>; |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 134 | pmic@68 { |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 135 | compatible = "dlg,da9121"; |
| 136 | reg = <0x68>; |
| 137 | |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 138 | interrupt-parent = <&gpio6>; |
| 139 | interrupts = <11 IRQ_TYPE_LEVEL_LOW>; |
| 140 | |
| 141 | dlg,irq-polling-delay-passive-ms = <2000>; |
| 142 | |
| 143 | regulators { |
| 144 | DA9121_BUCK1: buck1 { |
| 145 | regulator-name = "BUCK1"; |
| 146 | regulator-min-microvolt = <300000>; |
| 147 | regulator-max-microvolt = <1900000>; |
| 148 | regulator-min-microamp = <7000000>; |
| 149 | regulator-max-microamp = <20000000>; |
| 150 | regulator-boot-on; |
| 151 | regulator-initial-mode = <DA9121_BUCK_MODE_AUTO>; |
| 152 | enable-gpios = <&gpio 1 GPIO_ACTIVE_HIGH>; |
| 153 | }; |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 154 | }; |
| 155 | }; |
| 156 | }; |
| 157 | |
Adam Ward | 744ef9b | 2020-11-30 16:59:05 +0000 | [diff] [blame] | 158 | - | |
| 159 | #include <dt-bindings/gpio/gpio.h> |
| 160 | #include <dt-bindings/interrupt-controller/irq.h> |
| 161 | #include <dt-bindings/regulator/dlg,da9121-regulator.h> |
| 162 | i2c { |
| 163 | #address-cells = <1>; |
| 164 | #size-cells = <0>; |
| 165 | pmic@68 { |
| 166 | compatible = "dlg,da9122"; |
| 167 | reg = <0x68>; |
| 168 | |
| 169 | interrupt-parent = <&gpio6>; |
| 170 | interrupts = <11 IRQ_TYPE_LEVEL_LOW>; |
| 171 | |
| 172 | dlg,irq-polling-delay-passive-ms = <2000>; |
| 173 | |
| 174 | regulators { |
| 175 | DA9122_BUCK1: buck1 { |
| 176 | regulator-name = "BUCK1"; |
| 177 | regulator-min-microvolt = <300000>; |
| 178 | regulator-max-microvolt = <1900000>; |
| 179 | regulator-min-microamp = <3500000>; |
| 180 | regulator-max-microamp = <10000000>; |
| 181 | regulator-boot-on; |
| 182 | regulator-initial-mode = <DA9121_BUCK_MODE_AUTO>; |
| 183 | enable-gpios = <&gpio6 1 GPIO_ACTIVE_HIGH>; |
| 184 | dlg,ripple-cancel = <DA9121_BUCK_RIPPLE_CANCEL_NONE>; |
| 185 | }; |
| 186 | DA9122_BUCK2: buck2 { |
| 187 | regulator-name = "BUCK2"; |
| 188 | regulator-min-microvolt = <300000>; |
| 189 | regulator-max-microvolt = <1900000>; |
| 190 | regulator-min-microamp = <3500000>; |
| 191 | regulator-max-microamp = <10000000>; |
| 192 | regulator-boot-on; |
| 193 | regulator-initial-mode = <DA9121_BUCK_MODE_AUTO>; |
| 194 | enable-gpios = <&gpio6 2 GPIO_ACTIVE_HIGH>; |
| 195 | dlg,ripple-cancel = <DA9121_BUCK_RIPPLE_CANCEL_NONE>; |
| 196 | }; |
| 197 | }; |
| 198 | }; |
| 199 | }; |
Vincent Whitchurch | 1119c59 | 2020-11-03 11:00:20 +0100 | [diff] [blame] | 200 | ... |