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

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

Merge "power: smb5-lib: Fix wake lock acquisition"

parents 5099fdd0 3a272092
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -5878,6 +5878,12 @@ static void smblib_moisture_protection_work(struct work_struct *work)
	bool usb_plugged_in;
	u8 stat;

	/*
	 * Hold awake votable to prevent pm_relax being called prior to
	 * completion of this work.
	 */
	vote(chg->awake_votable, MOISTURE_VOTER, true, 0);

	/*
	 * Disable 1% duty cycle on CC_ID pin and enable uUSB factory mode
	 * detection to track any change on RID, as interrupts are disable.
@@ -5942,7 +5948,7 @@ static void smblib_moisture_protection_work(struct work_struct *work)
	}

out:
	pm_relax(chg->dev);
	vote(chg->awake_votable, MOISTURE_VOTER, false, 0);
}

static enum alarmtimer_restart moisture_protection_alarm_cb(struct alarm *alarm,