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

Commit 125cf2b8 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ARM: dts: msm: Enable 'qcom,qg-use-s7-ocv' for trinket"

parents 7ff70f8a 5fcb62e8
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -337,6 +337,11 @@ First Level Node - QGAUGE device
		    for the shutdown SOC to be used. If the difference is
		    beyond this value the PON SOC is used.

- qcom,qg-use-s7-ocv
	Usage:      optional
	Value type: <bool>
	Definition: Boolean property to use S7 for PON OCV.

==========================================================
Second Level Nodes - Peripherals managed by QGAUGE driver
==========================================================
+1 −0
Original line number Diff line number Diff line
@@ -134,6 +134,7 @@
	qcom,qg-iterm-ma = <100>;
	qcom,hold-soc-while-full;
	qcom,linearize-soc;
	qcom,qg-use-s7-ocv;
};

&pmi632_charger {
+1 −0
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@
	qcom,qg-iterm-ma = <100>;
	qcom,hold-soc-while-full;
	qcom,linearize-soc;
	qcom,qg-use-s7-ocv;
};

&pmi632_charger {
+1 −0
Original line number Diff line number Diff line
@@ -64,6 +64,7 @@ struct qg_dt {
	bool			esr_disable;
	bool			esr_discharge_enable;
	bool			qg_ext_sense;
	bool			use_s7_ocv;
};

struct qg_esr_data {
+5 −1
Original line number Diff line number Diff line
@@ -2886,7 +2886,9 @@ static int qg_set_wa_flags(struct qpnp_qg *chip)
{
	switch (chip->pmic_rev_id->pmic_subtype) {
	case PMI632_SUBTYPE:
		chip->wa_flags |= QG_RECHARGE_SOC_WA | QG_PON_OCV_WA;
		chip->wa_flags |= QG_RECHARGE_SOC_WA;
		if (!chip->dt.use_s7_ocv)
			chip->wa_flags |= QG_PON_OCV_WA;
		if (chip->pmic_rev_id->rev4 == PMI632_V1P0_REV4)
			chip->wa_flags |= QG_VBAT_LOW_WA;
		break;
@@ -3557,6 +3559,8 @@ static int qg_parse_dt(struct qpnp_qg *chip)

	chip->dt.qg_ext_sense = of_property_read_bool(node, "qcom,qg-ext-sns");

	chip->dt.use_s7_ocv = of_property_read_bool(node, "qcom,qg-use-s7-ocv");

	/* Capacity learning params*/
	if (!chip->dt.cl_disable) {
		chip->dt.cl_feedback_on = of_property_read_bool(node,