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

Commit 7d6cf8d0 authored by Anirudh Ghayal's avatar Anirudh Ghayal
Browse files

power: qpnp-smbcharger: Enable parallel charger if input is present



The parallel charger check in the fast-chg handler is only needed
in the enable parallel-charging path. Handle this by checking
for the input presence before configuring the parallel charger.

CRs-Fixed: 1089991
Change-Id: I7a12f62de0b8c36797511bac97ecbb9fbc1caf26
Signed-off-by: default avatarAnirudh Ghayal <aghayal@codeaurora.org>
parent 4fa286af
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -6498,8 +6498,12 @@ static irqreturn_t fastchg_handler(int irq, void *_chip)
	struct smbchg_chip *chip = _chip;

	pr_smb(PR_INTERRUPT, "p2f triggered\n");

	if (is_usb_present(chip) || is_dc_present(chip)) {
		smbchg_detect_parallel_charger(chip);
		smbchg_parallel_usb_check_ok(chip);
	}

	if (chip->psy_registered)
		power_supply_changed(&chip->batt_psy);
	smbchg_charging_status_change(chip);