1# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/mfd/rohm,bd71828-pmic.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: ROHM BD71828 Power Management Integrated Circuit 8 9maintainers: 10 - Matti Vaittinen <mazziesaccount@gmail.com> 11 12description: | 13 BD71828GW is a single-chip power management IC for battery-powered portable 14 devices. The IC integrates 7 buck converters, 7 LDOs, and a 1500 mA 15 single-cell linear charger. Also included is a Coulomb counter, a real-time 16 clock (RTC), and a 32.768 kHz clock gate. 17 18properties: 19 compatible: 20 oneOf: 21 - const: rohm,bd71828 22 23 - items: 24 - const: rohm,bd71879 25 - const: rohm,bd71828 26 27 reg: 28 description: 29 I2C slave address. 30 maxItems: 1 31 32 interrupts: 33 maxItems: 1 34 35 gpio-controller: true 36 37 "#gpio-cells": 38 const: 2 39 description: | 40 The first cell is the pin number and the second cell is used to specify 41 flags. See ../gpio/gpio.txt for more information. 42 43 clocks: 44 maxItems: 1 45 46 "#clock-cells": 47 const: 0 48 49 clock-output-names: 50 const: bd71828-32k-out 51 52 rohm,clkout-open-drain: 53 description: clk32kout mode. Set to 1 for "open-drain" or 0 for "cmos". 54 $ref: /schemas/types.yaml#/definitions/uint32 55 minimum: 0 56 maximum: 1 57 58 rohm,charger-sense-resistor-micro-ohms: 59 minimum: 10000 60 maximum: 50000 61 default: 30000 62 description: | 63 BD71827 and BD71828 have SAR ADC for measuring charging currents. 64 External sense resistor (RSENSE in data sheet) should be used. If some 65 other but 30mOhm resistor is used the resistance value should be given 66 here in microohms. 67 68 regulators: 69 $ref: /schemas/regulator/rohm,bd71828-regulator.yaml 70 description: 71 List of child nodes that specify the regulators. 72 73 leds: 74 $ref: /schemas/leds/rohm,bd71828-leds.yaml 75 76 gpio-reserved-ranges: 77 description: | 78 Usage of BD71828 GPIO pins can be changed via OTP. This property can be 79 used to mark the pins which should not be configured for GPIO. Please see 80 the ../gpio/gpio.txt for more information. 81 82 system-power-controller: true 83 84required: 85 - compatible 86 - reg 87 - interrupts 88 - clocks 89 - "#clock-cells" 90 - regulators 91 - gpio-controller 92 - "#gpio-cells" 93 94additionalProperties: false 95 96examples: 97 - | 98 #include <dt-bindings/interrupt-controller/irq.h> 99 #include <dt-bindings/leds/common.h> 100 i2c { 101 #address-cells = <1>; 102 #size-cells = <0>; 103 pmic: pmic@4b { 104 compatible = "rohm,bd71828"; 105 reg = <0x4b>; 106 107 interrupt-parent = <&gpio1>; 108 interrupts = <29 IRQ_TYPE_LEVEL_LOW>; 109 110 clocks = <&osc 0>; 111 #clock-cells = <0>; 112 clock-output-names = "bd71828-32k-out"; 113 114 gpio-controller; 115 #gpio-cells = <2>; 116 gpio-reserved-ranges = <0 1>, <2 1>; 117 118 rohm,charger-sense-resistor-micro-ohms = <10000>; 119 120 regulators { 121 buck1: BUCK1 { 122 regulator-name = "buck1"; 123 regulator-min-microvolt = <500000>; 124 regulator-max-microvolt = <2000000>; 125 regulator-ramp-delay = <2500>; 126 }; 127 buck2: BUCK2 { 128 regulator-name = "buck2"; 129 regulator-min-microvolt = <500000>; 130 regulator-max-microvolt = <2000000>; 131 regulator-ramp-delay = <2500>; 132 }; 133 buck3: BUCK3 { 134 regulator-name = "buck3"; 135 regulator-min-microvolt = <1200000>; 136 regulator-max-microvolt = <2000000>; 137 }; 138 buck4: BUCK4 { 139 regulator-name = "buck4"; 140 regulator-min-microvolt = <1000000>; 141 regulator-max-microvolt = <1800000>; 142 }; 143 buck5: BUCK5 { 144 regulator-name = "buck5"; 145 regulator-min-microvolt = <2500000>; 146 regulator-max-microvolt = <3300000>; 147 }; 148 buck6: BUCK6 { 149 regulator-name = "buck6"; 150 regulator-min-microvolt = <500000>; 151 regulator-max-microvolt = <2000000>; 152 regulator-ramp-delay = <2500>; 153 }; 154 buck7: BUCK7 { 155 regulator-name = "buck7"; 156 regulator-min-microvolt = <500000>; 157 regulator-max-microvolt = <2000000>; 158 regulator-ramp-delay = <2500>; 159 }; 160 ldo1: LDO1 { 161 regulator-name = "ldo1"; 162 regulator-min-microvolt = <800000>; 163 regulator-max-microvolt = <3300000>; 164 }; 165 ldo2: LDO2 { 166 regulator-name = "ldo2"; 167 regulator-min-microvolt = <800000>; 168 regulator-max-microvolt = <3300000>; 169 }; 170 ldo3: LDO3 { 171 regulator-name = "ldo3"; 172 regulator-min-microvolt = <800000>; 173 regulator-max-microvolt = <3300000>; 174 }; 175 ldo4: LDO4 { 176 regulator-name = "ldo4"; 177 regulator-min-microvolt = <800000>; 178 regulator-max-microvolt = <3300000>; 179 }; 180 ldo5: LDO5 { 181 regulator-name = "ldo5"; 182 regulator-min-microvolt = <800000>; 183 regulator-max-microvolt = <3300000>; 184 }; 185 ldo6: LDO6 { 186 regulator-name = "ldo6"; 187 regulator-min-microvolt = <1800000>; 188 regulator-max-microvolt = <1800000>; 189 }; 190 ldo7_reg: LDO7 { 191 regulator-name = "ldo7"; 192 regulator-min-microvolt = <800000>; 193 regulator-max-microvolt = <3300000>; 194 }; 195 }; 196 197 leds { 198 compatible = "rohm,bd71828-leds"; 199 200 led-1 { 201 rohm,led-compatible = "bd71828-grnled"; 202 function = LED_FUNCTION_INDICATOR; 203 color = <LED_COLOR_ID_GREEN>; 204 }; 205 led-2 { 206 rohm,led-compatible = "bd71828-ambled"; 207 function = LED_FUNCTION_CHARGING; 208 color = <LED_COLOR_ID_AMBER>; 209 }; 210 }; 211 }; 212 }; 213