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

Commit 2c32f734 authored by Lucille Sylvester's avatar Lucille Sylvester
Browse files

msm: kgsl: Change call timing to alleviate mutex contention



Finish the state transition in the _idle_check function before
calling to update devfreq.  With this reordering the devfreq
notifier won't be stalled waiting for the GPU's device mutex.

Change-Id: I887d9b9d67292b0526de8f9692ff9f210a189fa5
Signed-off-by: default avatarLucille Sylvester <lsylvest@codeaurora.org>
parent 018ecdd9
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -1208,8 +1208,6 @@ void kgsl_idle_check(struct work_struct *work)

	mutex_lock(&device->mutex);

	kgsl_pwrscale_update(device);

	if (device->state == KGSL_STATE_ACTIVE
		   || device->state ==  KGSL_STATE_NAP) {

@@ -1234,6 +1232,7 @@ void kgsl_idle_check(struct work_struct *work)
		}
	}

	kgsl_pwrscale_update(device);
	mutex_unlock(&device->mutex);
}
EXPORT_SYMBOL(kgsl_idle_check);