Browse Source

disp: msm: sde: flush pp event work queue before vm release

In some vm transitions, pp work might get executed on event thread
after handoff is completed on commit thread leading to crash.
This change flushes the pp event thread queue during vm pre-release
before lending the io resources to the other vm.

Change-Id: I53b76e48bc15084aa5519409fae0e692f49e7558
Signed-off-by: Saurabh Yadav <[email protected]>
Signed-off-by: Lakshmi Narayana Kalavala <[email protected]>
Saurabh Yadav 2 years ago
parent
commit
ac9d215e9e
1 changed files with 2 additions and 0 deletions
  1. 2 0
      msm/sde/sde_kms.c

+ 2 - 0
msm/sde/sde_kms.c

@@ -1457,6 +1457,8 @@ int sde_kms_vm_pre_release(struct sde_kms *sde_kms,
 	sde_kms_cancel_delayed_work(crtc);
 
 	kthread_flush_worker(&priv->event_thread[crtc->index].worker);
+	/* Flush pp_event thread queue for any pending events */
+	kthread_flush_worker(&priv->pp_event_worker);
 
 	/* disable SDE encoder irq's */
 	drm_for_each_encoder_mask(encoder, crtc->dev,