ecore_drm2: Perform test flip during plane assignment

Make sure we can commit that plane at assign time so when we hook up to
the scene graph it knows when it can safely use a plane.
This commit is contained in:
Derek Foreman 2017-04-27 15:53:16 -05:00
parent 8d42d7d50a
commit 6482367aa2
1 changed files with 8 additions and 0 deletions

View File

@ -109,6 +109,14 @@ out:
DBG("FB %d assigned to Plane %d", fb->id, pstate->obj_id);
output->planes = eina_list_append(output->planes, plane);
if (!_fb_atomic_flip_test(output))
{
output->planes = eina_list_remove(output->planes, plane);
plane->state->in_use = EINA_FALSE;
free(plane);
return NULL;
}
return plane;
}