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

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

Merge "power: smb135x-charger: Disable TEMP MONITOR in parallel charger mode"

parents 83f4b468 d1f83ece
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -112,6 +112,7 @@
#define BATT_MISSING_THERM_BIT		BIT(1)

#define CFG_1A_REG			0x1A
#define TEMP_MONITOR_EN_BIT		BIT(6)
#define HOT_SOFT_VFLOAT_COMP_EN_BIT	BIT(3)
#define COLD_SOFT_VFLOAT_COMP_EN_BIT	BIT(2)
#define HOT_SOFT_CURRENT_COMP_EN_BIT	BIT(1)
@@ -1814,6 +1815,15 @@ static int smb135x_parallel_set_chg_present(struct smb135x_chg *chip,
			return rc;
		}

		/* disable thermal monitoring for parallel-charger */
		rc = smb135x_masked_write(chip, CFG_1A_REG,
					TEMP_MONITOR_EN_BIT, 0);
		if (rc < 0) {
			dev_err(chip->dev,
				"Couldn't disable temp-monitor rc=%d\n", rc);
			return rc;
		}

		/* set the float voltage */
		if (chip->vfloat_mv != -EINVAL) {
			rc = smb135x_float_voltage_set(chip, chip->vfloat_mv);