power: supply: bq25890: On the bq25892 set the IINLIM based on external charger detection
authorHans de Goede <hdegoede@redhat.com>
Tue, 1 Feb 2022 13:06:57 +0000 (14:06 +0100)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Tue, 1 Feb 2022 13:55:12 +0000 (14:55 +0100)
commiteab25b4f93aa771728127705eb4b235a3b5aad94
treeb6d48d9596e1fa5a20cf2fcedaf534f7e89b4c4b
parent79d35365a5858466ff7b37aaf1fcf11b683b9442
power: supply: bq25890: On the bq25892 set the IINLIM based on external charger detection

The bq25892 does not have builtin charger-type detection like the bq25980,
there might be some external charger detection capability, which will be
modelled as a power_supply class-device supplying the bq25892.

Use the usb_type property value from the supplier psy-device to set the
input-current-limit (when available).

Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/bq25890_charger.c