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

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

Merge "msm: kgsl: Fix gdsc disable timeout during reset"

parents 824167f1 d14dbe68
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -1272,7 +1272,15 @@ static const char *a6xx_fault_block_uche(struct kgsl_device *device,
	unsigned int uche_client_id = 0;
	static char str[40];

	mutex_lock(&device->mutex);
	/*
	 * Smmu driver takes a vote on CX gdsc before calling the kgsl
	 * pagefault handler. If there is contention for device mutex in this
	 * path and the dispatcher fault handler is holding this lock, trying
	 * to turn off CX gdsc will fail during the reset. So to avoid blocking
	 * here, try to lock device mutex and return if it fails.
	 */
	if (!mutex_trylock(&device->mutex))
		return "UCHE: unknown";

	if (!kgsl_state_is_awake(device)) {
		mutex_unlock(&device->mutex);