power: qpnp-charger: resume charging correctly after EoC
Currently, there can be a race condition when charging ends at 99%
battery state of charge (SoC), but BMS does not immediately report
100%. This causes the charger to immediately resume charging because
SoC is below 100.
Fix this by recalculating the battery SoC in the BMS driver
immediately when getting a power supply notification from the
charger. Also have the charger check the BMS power supply status to
make sure that the BMS knows that the battery is not charging before
resuming charging.
Change-Id: I40388b6067ec1ec6d6433a6f6694e449f6fcb48f
Signed-off-by:
Xiaozhe Shi <xiaozhes@codeaurora.org>
Loading
Please register or sign in to comment