Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c2e1b77 authored by Zhenhua Huang's avatar Zhenhua Huang
Browse files

power: smb358-charger: Conditionally update battery status in term handler



On SMB, battery termination status updates even when we disable
charging termination. Handle this case by updating the battery status
only if required.

CRs-Fixed: 771020
Change-Id: I37f703d423785e23fd90a7736ffd13ffaf10982f
Signed-off-by: default avatarZhenhua Huang <zhenhuah@codeaurora.org>
parent 88ada96a
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1345,6 +1345,7 @@ static int fast_chg(struct smb358_charger *chip, u8 status)
static int chg_term(struct smb358_charger *chip, u8 status)
{
	dev_dbg(chip->dev, "%s\n", __func__);
	if (!chip->iterm_disabled)
		chip->batt_full = !!status;
	return 0;
}