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

Commit 2eec26e7 authored by Subbaraman Narayanamurthy's avatar Subbaraman Narayanamurthy
Browse files

power: qpnp-fg-gen4: Fix using uninitialized mutex lock



Initialize the mutex lock used for TTF calculation before using
it.

Change-Id: I938f7aa903e45020bcd2cab2e2eaf6df35ca53b7
Signed-off-by: default avatarSubbaraman Narayanamurthy <subbaram@codeaurora.org>
parent ff810a30
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -3143,6 +3143,7 @@ static int fg_gen4_probe(struct platform_device *pdev)
	mutex_init(&fg->bus_lock);
	mutex_init(&fg->sram_rw_lock);
	mutex_init(&fg->charge_full_lock);
	mutex_init(&chip->ttf.lock);
	init_completion(&fg->soc_update);
	init_completion(&fg->soc_ready);
	INIT_WORK(&fg->status_change_work, status_change_work);