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

Commit 0c3ada08 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: kgsl: Avoid spin lock recursion in adreno_drawctxt_dump"

parents 339f84f7 48ec5471
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -60,7 +60,12 @@ void adreno_drawctxt_dump(struct kgsl_device *device,
	kgsl_readtimestamp(device, context, KGSL_TIMESTAMP_CONSUMED, &start);
	kgsl_readtimestamp(device, context, KGSL_TIMESTAMP_RETIRED, &retire);

	spin_lock(&drawctxt->lock);
	/*
	 * We may have cmdbatch timer running, which also uses same
	 * lock, take a lock with software interrupt disabled (bh)
	 * to avoid spin lock recursion.
	 */
	spin_lock_bh(&drawctxt->lock);
	dev_err(device->dev,
		"  context[%d]: queue=%d, submit=%d, start=%d, retire=%d\n",
		context->id, queue, drawctxt->submitted_timestamp,
@@ -108,7 +113,7 @@ stats:
	dev_err(device->dev, "  context[%d]: submit times: %s\n",
		context->id, buf);

	spin_unlock(&drawctxt->lock);
	spin_unlock_bh(&drawctxt->lock);
}

/**