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

Commit 1318a174 authored by Anirudh Ghayal's avatar Anirudh Ghayal
Browse files

power: qpnp-qg: Skip reading battery-temp in the resume path



Reading the battery-temperature in the system_resume path is
not required. This also leads to VADC stalling as the EOC
irq is not enabled in the no_irq() callback.

Change-Id: I417d46cc07f455792906a18f4b6dc8e5ca8ca3df
Signed-off-by: default avatarAnirudh Ghayal <aghayal@codeaurora.org>
parent a4cb23ac
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -3442,7 +3442,7 @@ static int process_resume(struct qpnp_qg *chip)
{
	u8 status2 = 0, rt_status = 0;
	u32 ocv_uv = 0, ocv_raw = 0;
	int rc, batt_temp = 0;
	int rc;

	/* skip if profile is not loaded */
	if (!chip->profile_loaded)
@@ -3460,11 +3460,6 @@ static int process_resume(struct qpnp_qg *chip)
			pr_err("Failed to read good_ocv, rc=%d\n", rc);
			return rc;
		}
		rc = qg_get_battery_temp(chip, &batt_temp);
		if (rc < 0) {
			pr_err("Failed to read BATT_TEMP, rc=%d\n", rc);
			return rc;
		}

		 /* Clear suspend data as there has been a GOOD OCV */
		memset(&chip->kdata, 0, sizeof(chip->kdata));