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

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

Merge "power: qpnp-smbcharger: Hold wake lock for HVDCP detection"

parents 25c26c5b b5e31cbe
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -322,6 +322,7 @@ enum wake_reason {
	PM_REASON_VFLOAT_ADJUST = BIT(1),
	PM_ESR_PULSE = BIT(2),
	PM_PARALLEL_TAPER = BIT(3),
	PM_DETECT_HVDCP = BIT(4),
};

enum fcc_voters {
@@ -4449,6 +4450,7 @@ static void smbchg_hvdcp_det_work(struct work_struct *work)
			power_supply_changed(&chip->batt_psy);
		smbchg_aicl_deglitch_wa_check(chip);
	}
	smbchg_relax(chip, PM_DETECT_HVDCP);
}

static int set_usb_psy_dp_dm(struct smbchg_chip *chip, int state)
@@ -4670,6 +4672,7 @@ static void handle_usb_insertion(struct smbchg_chip *chip)
	if (!chip->hvdcp_not_supported &&
			(usb_supply_type == POWER_SUPPLY_TYPE_USB_DCP)) {
		cancel_delayed_work_sync(&chip->hvdcp_det_work);
		smbchg_stay_awake(chip, PM_DETECT_HVDCP);
		schedule_delayed_work(&chip->hvdcp_det_work,
					msecs_to_jiffies(HVDCP_NOTIFY_MS));
	}