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

Commit 8e680a1f authored by Jordan Crouse's avatar Jordan Crouse Committed by Shubhraprakash Das
Browse files

msm: kgsl: Run the event group after the context is invalidated



After a context is invalidated force the context event group to run
to process all the pending events.  If the context is invalidated
but not yet destroyed there might be dangling fence or freememontimestamp
events that will go unrun.

CRs-Fixed: 710362
Change-Id: Ic0dedbad5976236d811b50af87fbff038f639dc0
Signed-off-by: default avatarJordan Crouse <jcrouse@codeaurora.org>
parent 8963ea2d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -150,6 +150,7 @@ void adreno_drawctxt_invalidate(struct kgsl_device *device,
			KGSL_MEMSTORE_OFFSET(context->id, eoptimestamp),
			drawctxt->timestamp);

	/* Get rid of commands still waiting in the queue */
	while (drawctxt->cmdqueue_head != drawctxt->cmdqueue_tail) {
		struct kgsl_cmdbatch *cmdbatch =
			drawctxt->cmdqueue[drawctxt->cmdqueue_head];
@@ -170,6 +171,9 @@ void adreno_drawctxt_invalidate(struct kgsl_device *device,

	mutex_unlock(&drawctxt->mutex);

	/* Make sure all "retired" events are processed */
	kgsl_process_event_group(device, &context->events);

	/* Give the bad news to everybody waiting around */
	wake_up_all(&drawctxt->waiting);
	wake_up_all(&drawctxt->wq);