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

Commit 72ba595f authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "power: fg/smbcharger:add support for PMI8940"

parents bdcc0678 0fef82e1
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -107,6 +107,7 @@ enum pmic_subtype {
	PMI8950		= 17,
	PMI8996		= 19,
	PMI8937		= 55,
	PMI8940		= 64,
};

enum wa_flags {
@@ -7534,6 +7535,7 @@ static int fg_hw_init(struct fg_chip *chip)
		break;
	case PMI8950:
	case PMI8937:
	case PMI8940:
		rc = fg_8950_hw_init(chip);
		/* Setup workaround flag based on PMIC type */
		chip->wa_flag |= BCL_HI_POWER_FOR_CHGLED_WA;
@@ -7871,6 +7873,7 @@ static int fg_detect_pmic_type(struct fg_chip *chip)
	case PMI8950:
	case PMI8937:
	case PMI8996:
	case PMI8940:
		chip->pmic_subtype = pmic_rev_id->pmic_subtype;
		chip->pmic_revision[REVID_RESERVED]	= pmic_rev_id->rev1;
		chip->pmic_revision[REVID_VARIANT]	= pmic_rev_id->rev2;
+6 −1
Original line number Diff line number Diff line
@@ -295,6 +295,7 @@ enum pmic_subtype {
	PMI8950		= 17,
	PMI8996		= 19,
	PMI8937		= 55,
	PMI8940		= 64,
};

enum smbchg_wa {
@@ -7869,6 +7870,8 @@ static int smbchg_check_chg_version(struct smbchg_chip *chip)
	case PMI8950:
		chip->wa_flags |= SMBCHG_RESTART_WA;
	case PMI8937:
		/* fall through */
	case PMI8940:
		chip->wa_flags |= SMBCHG_BATT_OV_WA;
		if (pmic_rev_id->rev4 < 2) /* PMI8950 1.0 */ {
			chip->wa_flags |= SMBCHG_AICL_DEGLITCH_WA;
@@ -7883,7 +7886,9 @@ static int smbchg_check_chg_version(struct smbchg_chip *chip)
			ARRAY_SIZE(aicl_rerun_period_schg_lite);

		chip->schg_version = QPNP_SCHG_LITE;
		if (pmic_rev_id->pmic_subtype == PMI8937)
		/* PMI8937/PMI8940 doesn't support HVDCP */
		if ((pmic_rev_id->pmic_subtype == PMI8937)
			|| (pmic_rev_id->pmic_subtype == PMI8940))
			chip->hvdcp_not_supported = true;
		break;
	case PMI8996: