wl_egl: queue force flush will be run in thread
AS-IS
- In case where can_dequeue returns timeout error,
the operation of forcibly flushing the tbm_queue and
emptying buffer list of wl_egl_surface were performed in
the parent thread (dequeue thread).
PROBLEMS
- Whenever a buffer lis is traversed, the thread should be paused,
but the timeout error is often occured in pausing operation.
- In order to flush tbm_queue, it is necessary to use complex
mutex locking.
TO-BE
- The operation of emptying the queue and buffer list is performed
in the wl-egl-thread.
- The parent thread waits for the operation in the wl-egl-thread
to be completed, and in the following cases, it is regarded as an
error situation and causes the dequeue to return NULL.
1. If the result of tpl_gcond_timed_wait is a timeout error
2. If the result of tbm_surface_queue_can_dequeue is not 1 even
after receiving the signal from the wl-egl-thread.
Change-Id: Ibe65330f508d2193a02fd5fe43ba1b651dc0499c
Signed-off-by: Joonbum Ko <joonbum.ko@samsung.com>