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

Commit 47a0d824 authored by Todd Poynor's avatar Todd Poynor Committed by Ruchi Kandoi
Browse files

power: android-battery: use freezable workqueue for monitor



Alarmtimer may execute the monitor early in the resume sequence.  Freeze the
monitor while suspended, and unfreeze after the battery charger and fuel gauge,
etc. drivers are resumed.

Change-Id: Iefda1c642d4b2440169d90d2bee2888fc70e030a
Signed-off-by: default avatarTodd Poynor <toddpoynor@google.com>
parent f68c7efe
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -627,7 +627,7 @@ static int android_bat_probe(struct platform_device *pdev)
	}
	}


	battery->monitor_wqueue =
	battery->monitor_wqueue =
		create_singlethread_workqueue(dev_name(&pdev->dev));
		alloc_workqueue(dev_name(&pdev->dev), WQ_FREEZABLE, 1);
	if (!battery->monitor_wqueue) {
	if (!battery->monitor_wqueue) {
		dev_err(battery->dev, "%s: fail to create workqueue\n",
		dev_err(battery->dev, "%s: fail to create workqueue\n",
				__func__);
				__func__);