1# SPDX-License-Identifier: GPL-2.0 2# Copyright (C) 2021 Sebastian Reichel 3%YAML 1.2 4--- 5$id: "http://devicetree.org/schemas/power/supply/bq2415x.yaml#" 6$schema: "http://devicetree.org/meta-schemas/core.yaml#" 7 8title: Binding for TI bq2415x Li-Ion Charger 9 10maintainers: 11 - Sebastian Reichel <sre@kernel.org> 12 13allOf: 14 - $ref: power-supply.yaml# 15 16properties: 17 compatible: 18 enum: 19 - ti,bq24150 20 - ti,bq24150 21 - ti,bq24150a 22 - ti,bq24151 23 - ti,bq24151a 24 - ti,bq24152 25 - ti,bq24153 26 - ti,bq24153a 27 - ti,bq24155 28 - ti,bq24156 29 - ti,bq24156a 30 - ti,bq24158 31 32 reg: 33 maxItems: 1 34 35 ti,current-limit: 36 $ref: /schemas/types.yaml#/definitions/uint32 37 description: initial maximum current charger can pull from power supply in mA. 38 39 ti,weak-battery-voltage: 40 $ref: /schemas/types.yaml#/definitions/uint32 41 description: | 42 weak battery voltage threshold in mV. 43 The chip will use slow precharge if battery voltage is below this value. 44 45 ti,battery-regulation-voltage: 46 $ref: /schemas/types.yaml#/definitions/uint32 47 description: maximum charging voltage in mV. 48 49 ti,charge-current: 50 $ref: /schemas/types.yaml#/definitions/uint32 51 description: maximum charging current in mA. 52 53 ti,termination-current: 54 $ref: /schemas/types.yaml#/definitions/uint32 55 description: | 56 charge will be terminated when current in constant-voltage phase drops 57 below this value (in mA). 58 59 ti,resistor-sense: 60 $ref: /schemas/types.yaml#/definitions/uint32 61 description: value of sensing resistor in milliohm. 62 63 ti,usb-charger-detection: 64 $ref: /schemas/types.yaml#/definitions/phandle 65 description: phandle to usb charger detection device (required for auto mode) 66 67required: 68 - compatible 69 - reg 70 - ti,current-limit 71 - ti,weak-battery-voltage 72 - ti,battery-regulation-voltage 73 - ti,charge-current 74 - ti,termination-current 75 - ti,resistor-sense 76 77additionalProperties: false 78 79examples: 80 - | 81 i2c0 { 82 #address-cells = <1>; 83 #size-cells = <0>; 84 85 charger@6b { 86 compatible = "ti,bq24150a"; 87 reg = <0x6b>; 88 89 ti,current-limit = <100>; 90 ti,weak-battery-voltage = <3400>; 91 ti,battery-regulation-voltage = <4200>; 92 ti,charge-current = <650>; 93 ti,termination-current = <100>; 94 ti,resistor-sense = <68>; 95 96 ti,usb-charger-detection = <&isp1704>; 97 }; 98 }; 99