Hi,

On 03/01/17 01:29, Laurent Pinchart wrote:
> The driver currently handles vblank events only when updating planes on
> an already enabled CRTC. The atomic update API however allows requesting
> an event when enabling or disabling a CRTC. This currently leads to
> event objects being leaked in the kernel and to events not being sent
> out. Fix it.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> ---

> @@ -351,6 +363,13 @@ static void omap_crtc_disable(struct drm_crtc *crtc)
>  
>       DBG("%s", omap_crtc->name);
>  
> +     spin_lock_irq(&crtc->dev->event_lock);
> +     if (crtc->state->event) {
> +             drm_crtc_send_vblank_event(crtc, crtc->state->event);
> +             crtc->state->event = NULL;
> +     }
> +     spin_unlock_irq(&crtc->dev->event_lock);
> +
>       drm_crtc_vblank_off(crtc);
>  }

Hmm... How does this go... omap_crtc_dss_disable(), which is called via
the encoder's disable, is synchronous and waits until the output has
been disabled. Is omap_crtc_disable() called before or after that? If
before, we're sending the event too soon.

We need to fix the enable/disable call chains =).

 Tomi

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: 
<https://lists.freedesktop.org/archives/dri-devel/attachments/20170103/0285cc85/attachment-0001.sig>

Reply via email to