diff options
author | Derek Foreman <derekf@osg.samsung.com> | 2016-09-22 13:20:13 -0500 |
---|---|---|
committer | Chris Michael <cp.michael@samsung.com> | 2016-09-22 14:24:56 -0400 |
commit | de5305e2243f8b2cde7ab04e629422a1c0f8a6c0 (patch) | |
tree | d97d166676a4ae97714339386b87729799b46dcf | |
parent | 84cb88fe8c4880546fdeb9678ef7410a74ef448a (diff) | |
download | efl-de5305e2243f8b2cde7ab04e629422a1c0f8a6c0.tar.gz |
ecore-drm2: Merge initial modesetting with atomic flip code
-rw-r--r-- | src/lib/ecore_drm2/ecore_drm2_fb.c | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_fb.c b/src/lib/ecore_drm2/ecore_drm2_fb.c index 012751978a..0ba6680476 100644 --- a/src/lib/ecore_drm2/ecore_drm2_fb.c +++ b/src/lib/ecore_drm2/ecore_drm2_fb.c @@ -357,7 +357,8 @@ ecore_drm2_fb_flip(Ecore_Drm2_Fb *fb, Ecore_Drm2_Output *output) { Ecore_Drm2_Plane_State *pstate; uint32_t flags = - DRM_MODE_ATOMIC_NONBLOCK | DRM_MODE_PAGE_FLIP_EVENT; + DRM_MODE_ATOMIC_NONBLOCK | DRM_MODE_PAGE_FLIP_EVENT | + DRM_MODE_ATOMIC_ALLOW_MODSET; pstate = output->plane_state; @@ -373,26 +374,6 @@ ecore_drm2_fb_flip(Ecore_Drm2_Fb *fb, Ecore_Drm2_Output *output) pstate->cw.value = output->current_mode->width; pstate->ch.value = output->current_mode->height; - if ((!output->current) || - (output->current->stride != fb->stride)) - { - flags = DRM_MODE_ATOMIC_ALLOW_MODESET; - - ret = _fb_atomic_flip(output, pstate, flags); - if (ret < 0) - { - ERR("\tCrtc: %d FB: %d", output->crtc_id, fb->id); - return ret; - } - - if (output->current) _release_buffer(output, output->current); - output->current = fb; - output->current->busy = EINA_TRUE; - output->next = NULL; - - return 0; - } - ret = _fb_atomic_flip(output, pstate, flags); if ((ret < 0) && (errno != EBUSY)) { |