[RFC weston 00/14] Atomic modesetting support

Daniel Vetter daniel at ffwll.ch
Mon May 25 04:48:21 PDT 2015


On Fri, May 22, 2015 at 1:51 PM, Pekka Paalanen <ppaalanen at gmail.com> wrote:
> I just remembered, that this patch series does not excercise
> DRM_MODE_ATOMIC_TEST_ONLY. Using it would be quite some more
> refactoring.
>
> In Weston's assign_planes(), we would need to start with a
> drmModeAtomicReq that sets only the primary plane. Then one by one, for
> each weston_surface that can go on a DRM plane, add it to the req
> and do a test commit. If the test commit fails, remove the
> weston_surface from the req and stop or try other
> weston_surfaces. Once that completes, we know what set of plane updates
> will succeed, and only then we can launch the composite rendering for
> the rest.
>
> However, removing a plane update from a req is not possible,
> right? You have to just destroy the whole thing and reconstruct it
> without the bad update.
>
> Could there be some kind of libdrm API for marking points in a req
> and then the ability to remove all updates added after the mark?
>
> Or just to make copy of the req before adding a tentative new
> plane, but then we have to create and destroy copies a lot, also in the
> case where everything is ok.

You could also just clear the plane->crtc link and the plane's
framebuffer and that's enough to disable a plane. Should be a lot
simpler than adding rollback support to libdrm.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch


More information about the wayland-devel mailing list