]> git.itanic.dy.fi Git - linux-stable/commit
power: supply: bq27xxx: After charger plug in/out wait 0.5s for things to stabilize
authorHans de Goede <hdegoede@redhat.com>
Sat, 15 Apr 2023 18:23:38 +0000 (20:23 +0200)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Mon, 8 May 2023 13:29:12 +0000 (15:29 +0200)
commit59a99cd462fbdf71f4e845e09f37783035088b4f
tree532c3db5c6a3f2663280e4aa914c41159ebc17d9
parent939a116142012926e25de0ea6b7e2f8d86a5f1b6
power: supply: bq27xxx: After charger plug in/out wait 0.5s for things to stabilize

bq27xxx_external_power_changed() gets called when the charger is plugged
in or out. Rather then immediately scheduling an update wait 0.5 seconds
for things to stabilize, so that e.g. the (dis)charge current is stable
when bq27xxx_battery_update() runs.

Fixes: 740b755a3b34 ("bq27x00: Poll battery state")
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/bq27xxx_battery.c