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

Commit 810aa28b authored by Harry Yang's avatar Harry Yang
Browse files

regulator: qpnp-labibb: modify IBB_SPARE_CTL setting during TTW mode exit



Currently for PMI8996, IBB_SPARE_CTL is configured to slower PFET turn off
while exiting out of TTW mode. As per the hardware documentation, this
setting needs to be modified to faster PFET turn off for both PMI8996,
PMI8994 and PMI8950. Modify it to improve IBB efficiency.

CRs-Fixed: 966167
Change-Id: I0693eb275eeab5c349b455da31a96ba6dbeb4cf9
Signed-off-by: default avatarHarry Yang <harryy@codeaurora.org>
parent a5f72ee3
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -1221,12 +1221,12 @@ static int qpnp_labibb_regulator_ttw_mode_enter(struct qpnp_labibb *labibb)
	return 0;
}

static int qpnp_labibb_ttw_exit_ibb_pmi8996(struct qpnp_labibb *labibb)
static int qpnp_labibb_ttw_exit_ibb_common(struct qpnp_labibb *labibb)
{
	int rc;
	u8 val;

	val = 0;
	val = IBB_FASTER_PFET_OFF;
	rc = qpnp_labibb_write(labibb, labibb->ibb_base + REG_IBB_SPARE_CTL,
			&val, 1);
	if (rc)
@@ -1284,7 +1284,9 @@ static int qpnp_labibb_regulator_ttw_mode_exit(struct qpnp_labibb *labibb)

	switch (labibb->pmic_rev_id->pmic_subtype) {
	case PMI8996:
		rc = qpnp_labibb_ttw_exit_ibb_pmi8996(labibb);
	case PMI8994:
	case PMI8950:
		rc = qpnp_labibb_ttw_exit_ibb_common(labibb);
		break;
	}
	if (rc) {