linux/Documentation/devicetree/bindings/power/supply/summit,smb347-charger.yaml
Linus Torvalds f7cdaeeab8 power supply and reset changes for the v6.0 series
power-supply core:
  - none
 
 drivers:
  - pwr-mlxbf: new reset driver for Mellanox BlueField
  - at91-reset: SAMA7G5 support
  - ab8500: continue refurbishing
  - misc. minor fixes
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE72YNB0Y/i3JqeVQT2O7X88g7+poFAmL1g+cACgkQ2O7X88g7
 +pqlSQ//bHOcpSskI+fVDkPNbInVdOW7eK+cVdkNyeeEgZMz86C7fcQQ3/LwLhpj
 Jw3PFhIKklNR6dk+hE3Q6Jw0gzMSBIeCILCPuHLOYc4rWgduUzTEO6gCxy+jtDt+
 cfUfP9RsfU47RYT6f5XL4K2Qlu0Plhpro+P7nECYubPRwYVnrpiMYDrOWNb68Yyb
 gcCjJN21nrQ4fJy/Qai1nUjlKAKJOmL6LBO/qe0EjVSllkGGGmAIDfolvXXmS1ku
 HZ5IEnpFp6usiXa52Q06QyWF6yp2WFsF1gACfWnimpj3lpPKcY4XSGR/rtAtu1ed
 qgxjmXoKCEy8z5WLjMlgNzOsVTMNSZyU4MWqrb4zQkR2GyaEqH2K1Hbp22Eu8qDC
 EHWel114aSHAooOhCXbl1mp7t+1aS+72buagmV2KuGMUMBf0jLKcTJahN0Czek3O
 EwrlN9INIMgcXZ2Ze7dEO6pJcdUov/fiOlB4rXE/cFIlSILT1dTuBPJCKrAqTePV
 7QMYMmTvlSEgdTxgc7c4FaP9+ILxkZ1EgKDvxETKLImevXyecngep8S+9uq2cVkA
 lYdt33MnOHMx0AktFjKS0EEU1zkYN0z+yT3/0uuqzfT5/5xdvIqedXqkncl3Mdqq
 Ckdnya9n5NGmQXDr+0iuKBe510+nZX3yf1exTBbogOf97uBYiR8=
 =ulQI
 -----END PGP SIGNATURE-----

Merge tag 'for-v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply

Pull power supply and reset updates from Sebastian Reichel:
 "No core patches, only driver updates:

   - pwr-mlxbf: new reset driver for Mellanox BlueField

   - at91-reset: SAMA7G5 support

   - ab8500: continue refurbishing

   - misc minor fixes"

* tag 'for-v6.0' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply: (29 commits)
  power: supply: olpc_battery: Hold the reference returned by of_find_compatible_node
  power: supply: ab8500: add missing destroy_workqueue in ab8500_charger_bind
  power: supply: ab8500: Remove flush_scheduled_work() call.
  power: supply: ab8500_fg: drop duplicated 'is' in comment
  power: supply: ab8500: Drop external charger leftovers
  power: supply: ab8500: Add MAINTAINERS entry
  dt-bindings: power: reset: qcom,pshold: convert to dtschema
  power: supply: Fix typo in power_supply_check_supplies
  power: reset: pwr-mlxbf: change rst_pwr_hid and low_pwr_hid from global to local variables
  power: reset: pwr-mlxbf: add missing include
  power: reset: at91-reset: add support for SAMA7G5
  power: reset: at91-reset: add reset_controller_dev support
  power: reset: at91-reset: add at91_reset_data
  power: reset: at91-reset: document structures and enums
  dt-bindings: reset: add sama7g5 definitions
  dt-bindings: reset: atmel,at91sam9260-reset: add sama7g5 bindings
  dt-bindings: reset: convert Atmel/Microchip reset controller to YAML
  power: reset: pwr-mlxbf: add BlueField SoC power control driver
  power: supply: ab8500: Exit maintenance if too low voltage
  power: supply: ab8500: Respect charge_restart_voltage_uv
  ...
2022-08-12 09:37:33 -07:00

183 lines
5.1 KiB
YAML

# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/power/supply/summit,smb347-charger.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Battery charger driver for SMB345, SMB347 and SMB358
maintainers:
- David Heidelberg <david@ixit.cz>
- Dmitry Osipenko <digetx@gmail.com>
properties:
compatible:
enum:
- summit,smb345
- summit,smb347
- summit,smb358
reg:
maxItems: 1
interrupts:
maxItems: 1
monitored-battery:
description: phandle to the battery node
$ref: /schemas/types.yaml#/definitions/phandle
summit,enable-usb-charging:
type: boolean
description: Enable charging through USB.
summit,enable-otg-charging:
type: boolean
description: Provide power for USB OTG
summit,enable-mains-charging:
type: boolean
description: Enable charging through mains
summit,enable-charge-control:
description: Enable charging control
$ref: /schemas/types.yaml#/definitions/uint32
enum:
- 0 # SMB3XX_CHG_ENABLE_SW SW (I2C interface)
- 1 # SMB3XX_CHG_ENABLE_PIN_ACTIVE_LOW Pin control (Active Low)
- 2 # SMB3XX_CHG_ENABLE_PIN_ACTIVE_HIGH Pin control (Active High)
summit,fast-voltage-threshold-microvolt:
description: Voltage threshold to transit to fast charge mode (in uV)
minimum: 2400000
maximum: 3000000
summit,mains-current-limit-microamp:
description: Maximum input current from AC/DC input (in uA)
summit,usb-current-limit-microamp:
description: Maximum input current from USB input (in uA)
summit,charge-current-compensation-microamp:
description: Charge current compensation (in uA)
summit,chip-temperature-threshold-celsius:
description: Chip temperature for thermal regulation in °C.
enum: [100, 110, 120, 130]
summit,soft-compensation-method:
description: Soft temperature limit compensation method
$ref: /schemas/types.yaml#/definitions/uint32
enum:
- 0 # SMB3XX_SOFT_TEMP_COMPENSATE_NONE Compensation none
- 1 # SMB3XX_SOFT_TEMP_COMPENSATE_CURRENT Current compensation
- 2 # SMB3XX_SOFT_TEMP_COMPENSATE_VOLTAGE Voltage compensation
summit,inok-polarity:
description: |
Polarity of INOK signal indicating presence of external power supply.
$ref: /schemas/types.yaml#/definitions/uint32
enum:
- 0 # SMB3XX_SYSOK_INOK_ACTIVE_LOW
- 1 # SMB3XX_SYSOK_INOK_ACTIVE_HIGH
usb-vbus:
$ref: /schemas/regulator/regulator.yaml#
type: object
properties:
summit,needs-inok-toggle:
type: boolean
description: INOK signal is fixed and polarity needs to be toggled
in order to enable/disable output mode.
unevaluatedProperties: false
allOf:
- if:
properties:
compatible:
enum:
- summit,smb345
- summit,smb358
then:
properties:
summit,mains-current-limit-microamp:
enum: [ 300000, 500000, 700000, 1000000,
1500000, 1800000, 2000000]
summit,usb-current-limit-microamp:
enum: [ 300000, 500000, 700000, 1000000,
1500000, 1800000, 2000000]
summit,charge-current-compensation-microamp:
enum: [200000, 450000, 600000, 900000]
else:
properties:
summit,mains-current-limit-microamp:
enum: [ 300000, 500000, 700000, 900000, 1200000,
1500000, 1800000, 2000000, 2200000, 2500000]
summit,usb-current-limit-microamp:
enum: [ 300000, 500000, 700000, 900000, 1200000,
1500000, 1800000, 2000000, 2200000, 2500000]
summit,charge-current-compensation-microamp:
enum: [250000, 700000, 900000, 1200000]
required:
- compatible
- reg
anyOf:
- required:
- summit,enable-usb-charging
- required:
- summit,enable-otg-charging
- required:
- summit,enable-mains-charging
additionalProperties: false
examples:
- |
#include <dt-bindings/power/summit,smb347-charger.h>
i2c {
#address-cells = <1>;
#size-cells = <0>;
charger@7f {
compatible = "summit,smb347";
reg = <0x7f>;
summit,enable-charge-control = <SMB3XX_CHG_ENABLE_PIN_ACTIVE_HIGH>;
summit,inok-polarity = <SMB3XX_SYSOK_INOK_ACTIVE_LOW>;
summit,chip-temperature-threshold-celsius = <110>;
summit,mains-current-limit-microamp = <2000000>;
summit,usb-current-limit-microamp = <500000>;
summit,enable-usb-charging;
summit,enable-mains-charging;
monitored-battery = <&battery>;
usb-vbus {
regulator-name = "usb_vbus";
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
regulator-min-microamp = <750000>;
regulator-max-microamp = <750000>;
summit,needs-inok-toggle;
};
};
};
battery: battery-cell {
compatible = "simple-battery";
constant-charge-current-max-microamp = <1800000>;
operating-range-celsius = <0 45>;
alert-celsius = <3 42>;
};