summaryrefslogtreecommitdiff
path: root/src/lib/ecore_drm2/ecore_drm2_fb.c
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2017-04-28 12:28:39 -0500
committerDerek Foreman <derekf@osg.samsung.com>2017-05-05 12:53:23 -0500
commitb6f67124e46d9be11c8b2fec36c3dd8fc7037d10 (patch)
tree0a8a21563ed0b99489dafb8deea76753ecaffd62 /src/lib/ecore_drm2/ecore_drm2_fb.c
parentba4d41ff638389c48a49dcafee8fa0e37635c23d (diff)
ecore_drm2: Add some atomic state tracking
I think we're now at the point where the two paths are merged. Still no atomic functionality because nothing assigned the primary plane, so we have no atomic state to commit. The machinery should be in place though.
Diffstat (limited to '')
-rw-r--r--src/lib/ecore_drm2/ecore_drm2_fb.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/lib/ecore_drm2/ecore_drm2_fb.c b/src/lib/ecore_drm2/ecore_drm2_fb.c
index 0228156356..f2c2bc09a7 100644
--- a/src/lib/ecore_drm2/ecore_drm2_fb.c
+++ b/src/lib/ecore_drm2/ecore_drm2_fb.c
@@ -231,6 +231,10 @@ ecore_drm2_fb_flip_complete(Ecore_Drm2_Output *output)
231 output->current.fb = output->pending.fb; 231 output->current.fb = output->pending.fb;
232 output->pending.fb = NULL; 232 output->pending.fb = NULL;
233 233
234#ifdef HAVE_ATOMIC_DRM
235 output->current.atomic_req = output->pending.atomic_req;
236 output->pending.atomic_req = NULL;
237#endif
234 return !!output->next.fb; 238 return !!output->next.fb;
235} 239}
236 240
@@ -491,6 +495,9 @@ ecore_drm2_fb_flip(Ecore_Drm2_Fb *fb, Ecore_Drm2_Output *output)
491 { 495 {
492 output->next.fb->busy = EINA_FALSE; 496 output->next.fb->busy = EINA_FALSE;
493 output->next.fb = NULL; 497 output->next.fb = NULL;
498#ifdef HAVE_ATOMIC_DRM
499 output->next.atomic_req = NULL;
500#endif
494 } 501 }
495 502
496 /* If we don't have an fb to set by now, BAIL! */ 503 /* If we don't have an fb to set by now, BAIL! */
@@ -503,10 +510,13 @@ ecore_drm2_fb_flip(Ecore_Drm2_Fb *fb, Ecore_Drm2_Output *output)
503 else 510 else
504 ret = _fb_flip(output); 511 ret = _fb_flip(output);
505 512
506 output->pending.fb = fb; 513 output->pending.fb = output->prep.fb;
507 output->pending.fb->busy = EINA_TRUE; 514 output->pending.fb->busy = EINA_TRUE;
508 output->prep.fb = NULL; 515 output->prep.fb = NULL;
509 516#ifdef HAVE_ATOMIC_DRM
517 output->pending.atomic_req = output->prep.atomic_req;
518 output->prep.atomic_req = NULL;
519#endif
510 return ret; 520 return ret;
511} 521}
512 522