wl_egl: Initialize vblank_done flag when dequeue timeout occured 14/291414/1
authorJoonbum Ko <joonbum.ko@samsung.com>
Fri, 14 Apr 2023 10:00:36 +0000 (19:00 +0900)
committerJoonbum Ko <joonbum.ko@samsung.com>
Fri, 14 Apr 2023 10:00:39 +0000 (19:00 +0900)
 - Rarely, even if client cannot receive vblank event from tdm server,
  timeout may occur in can_dequeue.
 - In this case, if wl_egl_surface->vblank_done flag
  is not initialized to TPL_TRUE, problem situation may occur
  waiting vblank without calling tdm_client_vblank_wait
  after force_flush(can_dequeue_timeout).

Change-Id: If3f8eee13b5ae91a3728f189f53aa25720696b12
Signed-off-by: Joonbum Ko <joonbum.ko@samsung.com>
src/tpl_wl_egl_thread.c

index 13b7404..16df22e 100755 (executable)
@@ -2604,6 +2604,8 @@ __tpl_wl_egl_surface_dequeue_buffer(tpl_surface_t *surface, uint64_t timeout_ns,
                        tsq_err = TBM_SURFACE_QUEUE_ERROR_NONE;
                }
 
+               wl_egl_surface->vblank_done = TPL_TRUE;
+
                tpl_gmutex_unlock(&wl_egl_display->wl_event_mutex);
                tpl_gthread_continue(wl_egl_display->thread);
        }