Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/mfd/rohm,bd71828-pmic.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: ROHM BD71828 Power Management Integrated Circuit bindings
0008 
0009 maintainers:
0010   - Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
0011 
0012 description: |
0013   BD71828GW is a single-chip power management IC for battery-powered portable
0014   devices. The IC integrates 7 buck converters, 7 LDOs, and a 1500 mA
0015   single-cell linear charger. Also included is a Coulomb counter, a real-time
0016   clock (RTC), and a 32.768 kHz clock gate.
0017 
0018 properties:
0019   compatible:
0020     const: rohm,bd71828
0021 
0022   reg:
0023     description:
0024       I2C slave address.
0025     maxItems: 1
0026 
0027   interrupts:
0028     maxItems: 1
0029 
0030   gpio-controller: true
0031 
0032   "#gpio-cells":
0033     const: 2
0034     description: |
0035       The first cell is the pin number and the second cell is used to specify
0036       flags. See ../gpio/gpio.txt for more information.
0037 
0038   clocks:
0039     maxItems: 1
0040 
0041   "#clock-cells":
0042     const: 0
0043 
0044   clock-output-names:
0045     const: bd71828-32k-out
0046 
0047   rohm,clkout-open-drain:
0048     description: clk32kout mode. Set to 1 for "open-drain" or 0 for "cmos".
0049     $ref: "/schemas/types.yaml#/definitions/uint32"
0050     minimum: 0
0051     maximum: 1
0052 
0053   rohm,charger-sense-resistor-ohms:
0054     minimum: 10000000
0055     maximum: 50000000
0056     description: |
0057       BD71827 and BD71828 have SAR ADC for measuring charging currents.
0058       External sense resistor (RSENSE in data sheet) should be used. If some
0059       other but 30MOhm resistor is used the resistance value should be given
0060       here in Ohms.
0061 
0062   regulators:
0063     $ref: ../regulator/rohm,bd71828-regulator.yaml
0064     description:
0065       List of child nodes that specify the regulators.
0066 
0067   leds:
0068     $ref: ../leds/rohm,bd71828-leds.yaml
0069 
0070   gpio-reserved-ranges:
0071     description: |
0072       Usage of BD71828 GPIO pins can be changed via OTP. This property can be
0073       used to mark the pins which should not be configured for GPIO. Please see
0074       the ../gpio/gpio.txt for more information.
0075 
0076 required:
0077   - compatible
0078   - reg
0079   - interrupts
0080   - clocks
0081   - "#clock-cells"
0082   - regulators
0083   - gpio-controller
0084   - "#gpio-cells"
0085 
0086 additionalProperties: false
0087 
0088 examples:
0089   - |
0090     #include <dt-bindings/interrupt-controller/irq.h>
0091     #include <dt-bindings/leds/common.h>
0092     i2c {
0093         #address-cells = <1>;
0094         #size-cells = <0>;
0095         pmic: pmic@4b {
0096             compatible = "rohm,bd71828";
0097             reg = <0x4b>;
0098 
0099             interrupt-parent = <&gpio1>;
0100             interrupts = <29 IRQ_TYPE_LEVEL_LOW>;
0101 
0102             clocks = <&osc 0>;
0103             #clock-cells = <0>;
0104             clock-output-names = "bd71828-32k-out";
0105 
0106             gpio-controller;
0107             #gpio-cells = <2>;
0108             gpio-reserved-ranges = <0 1>, <2 1>;
0109 
0110             rohm,charger-sense-resistor-ohms = <10000000>;
0111 
0112             regulators {
0113                 buck1: BUCK1 {
0114                     regulator-name = "buck1";
0115                     regulator-min-microvolt = <500000>;
0116                     regulator-max-microvolt = <2000000>;
0117                     regulator-ramp-delay = <2500>;
0118                 };
0119                 buck2: BUCK2 {
0120                     regulator-name = "buck2";
0121                     regulator-min-microvolt = <500000>;
0122                     regulator-max-microvolt = <2000000>;
0123                     regulator-ramp-delay = <2500>;
0124                 };
0125                 buck3: BUCK3 {
0126                     regulator-name = "buck3";
0127                     regulator-min-microvolt = <1200000>;
0128                     regulator-max-microvolt = <2000000>;
0129                 };
0130                 buck4: BUCK4 {
0131                     regulator-name = "buck4";
0132                     regulator-min-microvolt = <1000000>;
0133                     regulator-max-microvolt = <1800000>;
0134                 };
0135                 buck5: BUCK5 {
0136                     regulator-name = "buck5";
0137                     regulator-min-microvolt = <2500000>;
0138                     regulator-max-microvolt = <3300000>;
0139                 };
0140                 buck6: BUCK6 {
0141                     regulator-name = "buck6";
0142                     regulator-min-microvolt = <500000>;
0143                     regulator-max-microvolt = <2000000>;
0144                     regulator-ramp-delay = <2500>;
0145                 };
0146                 buck7: BUCK7 {
0147                     regulator-name = "buck7";
0148                     regulator-min-microvolt = <500000>;
0149                     regulator-max-microvolt = <2000000>;
0150                     regulator-ramp-delay = <2500>;
0151                 };
0152                 ldo1: LDO1 {
0153                     regulator-name = "ldo1";
0154                     regulator-min-microvolt = <800000>;
0155                     regulator-max-microvolt = <3300000>;
0156                 };
0157                 ldo2: LDO2 {
0158                     regulator-name = "ldo2";
0159                     regulator-min-microvolt = <800000>;
0160                     regulator-max-microvolt = <3300000>;
0161                 };
0162                 ldo3: LDO3 {
0163                     regulator-name = "ldo3";
0164                     regulator-min-microvolt = <800000>;
0165                     regulator-max-microvolt = <3300000>;
0166                 };
0167                 ldo4: LDO4 {
0168                     regulator-name = "ldo4";
0169                     regulator-min-microvolt = <800000>;
0170                     regulator-max-microvolt = <3300000>;
0171                 };
0172                 ldo5: LDO5 {
0173                     regulator-name = "ldo5";
0174                     regulator-min-microvolt = <800000>;
0175                     regulator-max-microvolt = <3300000>;
0176                 };
0177                 ldo6: LDO6 {
0178                     regulator-name = "ldo6";
0179                     regulator-min-microvolt = <1800000>;
0180                     regulator-max-microvolt = <1800000>;
0181                 };
0182                 ldo7_reg: LDO7 {
0183                     regulator-name = "ldo7";
0184                     regulator-min-microvolt = <800000>;
0185                     regulator-max-microvolt = <3300000>;
0186                 };
0187             };
0188 
0189             leds {
0190                 compatible = "rohm,bd71828-leds";
0191 
0192                 led-1 {
0193                     rohm,led-compatible = "bd71828-grnled";
0194                     function = LED_FUNCTION_INDICATOR;
0195                     color = <LED_COLOR_ID_GREEN>;
0196                 };
0197                 led-2 {
0198                     rohm,led-compatible = "bd71828-ambled";
0199                     function = LED_FUNCTION_CHARGING;
0200                     color = <LED_COLOR_ID_AMBER>;
0201                 };
0202             };
0203         };
0204     };