power: qpnp-charger: don't reset vddmax trim after EOC

Currently the vddmax trim is being calibrated during the constant
voltage charging in order to charge more accurately. However, when end
of charge happens, this trim is reset back to the original value. On
certain chips with very bad preset trims, this can actually cause the
charger to go into accidental reverse boost when USB is reinserted and
vbat is higher than vddmax by 60mV.

Fix this by not resetting the vddmax trim after EOC or USB removal.

CRs-Fixed: 657755
Change-Id: Iaf9c9eb786ee05e5f326fa87813fe867f6493829
Signed-off-by: Xiaozhe Shi <xiaozhes@codeaurora.org>
1 file changed