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

Commit 517dff83 authored by Subbaraman Narayanamurthy's avatar Subbaraman Narayanamurthy Committed by Gerrit - the friendly Code Review server
Browse files

power: qpnp-smbcharger: add low-volt-dcin device tree property



Currently, we do AICL deglitch configuration dynamically for all
type of chargers whereas it should be applied specifically. As a
part of that, we need to differentiate low volt DCIN chargers.

Add a device tree property to support that requirement. If this
property is set, then AICL deglitch configuration will be applied
dynamically.

CRs-Fixed: 800438
Change-Id: Id4843b0b758652a4a99e212f286ed09118503a8e
Signed-off-by: default avatarSubbaraman Narayanamurthy <subbaram@codeaurora.org>
parent e32562d8
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -219,6 +219,10 @@ Optional Properties:
				limit needs to be disabled. If it is not present,
				jeita temperature hard limit will be based on what
				the bootloader had set earlier.
- qcom,low-volt-dcin:		A boolean property which upon set will enable the
				AICL deglitch configuration dynamically. This needs
				to be set if the DCIN supply is going to be less
				than or equal to 5V.
- qcom,soft-vfloat-comp-disabled	Set this property when the battery is
					powered via external source and could
					go above the float voltage.
+3 −0
Original line number Diff line number Diff line
@@ -112,6 +112,7 @@ struct smbchg_chip {
	bool				charge_unknown_battery;
	bool				chg_inhibit_en;
	bool				chg_inhibit_source_fg;
	bool				low_volt_dcin;
	u8				original_usbin_allowance;
	struct parallel_usb_cfg		parallel;
	struct delayed_work		parallel_en_work;
@@ -4552,6 +4553,8 @@ static int smb_parse_dt(struct smbchg_chip *chip)
					"qcom,chg-inhibit-en");
	chip->chg_inhibit_source_fg = of_property_read_bool(node,
						"qcom,chg-inhibit-fg");
	chip->low_volt_dcin = of_property_read_bool(node,
					"qcom,low-volt-dcin");

	/* parse the battery missing detection pin source */
	rc = of_property_read_string(chip->spmi->dev.of_node,