[Intel-gfx] [RFC] DRI2 swapbuffers (yes yet again)
idr at freedesktop.org
Mon May 4 14:45:07 PDT 2009
-----BEGIN PGP SIGNED MESSAGE-----
Jesse Barnes wrote:
> Ok, this set addresses all the shortcomings of the last set, and things
> seem quite solid, aside from output detection on my test platform which
> causes me to wait on flips from pipes with no outputs attached. Note
> that this meant changing the locking semantics for the set_pipe_base
> call to avoid racing between the base update and getting a seqno for
> the vblank wait.
> Dave & Jakob suggested possibly making the ioctl KMS generic. I think
> this might be possible, but I'd appreciate review of it to make sure
> the interfaces look ok, since I'd like to push this out soon (this week
> if possible).
> This one still uses the setBuffers call, but I kind of like it now that
> I've worked with it more. It makes the DRI driver a little cleaner
> (separating actual buffer acquisition from renderbuffer updates), but
> I'm still open to better ways of doing it that don't involve a bunch
> more round trips.
> Overall, this patchset adds a new ioctl to the kernel,
> DRM_I915_GEM_PAGE_FLIP, with two flags, I915_PAGE_FLIP_WAIT and
> I915_PAGE_FLIP_ASYNC. PAGE_FLIP_WAIT will block the return of the
> ioctl until the flip completes (useful for throttling perhaps), while
> PAGE_FLIP_ASYNC queues the flip immediately and doesn't wait for any
> outstanding flips to finish.
> The ioctl is exposed in libdrm as drm_intel_flip_bufs(). New DRI2
> protocol is added to send swapbuffers requests to the server from DRI
> clients. The server and AIGLX clients call into the driver directly,
> and update client buffers with the returned value.
> I'm still working through mutlihead issues on the kernel side; the
> flip waits should wait for *both* vblank events before completing the
> flip. But other than that, I'm pretty happy with things.
> I'm attaching them this time because I don't want to send a ton of
> mail again.
There's a problem in dri2SwapBuffers. If a new libGL is used with an
old driver, psc->dri2->setBuffers won't be set, right?
Also, should there be a mechanism for the 3D driver to force swap
buffers to be implemented with a copy?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the Intel-gfx