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

Commit 84a85d89 authored by Rakesh Kota's avatar Rakesh Kota
Browse files

power: qpnp-fg-gen4: Update msoc on every FVSS soc update



There is possibility of a momentary SOC jump after we
exit the FVSS loop. Fix this by updating the msoc
on every FVSS soc update to make sure the soc value in
hardware tracks the FVSS scaled value.

Change-Id: I7a5638551615cc0d6da7171b05ffb2496cac4381
Signed-off-by: default avatarRakesh Kota <quic_kotarake@quicinc.com>
parent 34bb42eb
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -4120,6 +4120,8 @@ static void soc_scale_work(struct work_struct *work)

	mutex_unlock(&chip->soc_scale_lock);
	if (chip->prev_soc_scale_msoc != chip->soc_scale_msoc) {
		/* update MSOC */
		fg_gen4_write_scale_msoc(chip);
		if (batt_psy_initialized(fg))
			power_supply_changed(fg->batt_psy);
	}