[Intel-gfx] [PATCH] i915: add page flipping support

Jesse Barnes jbarnes at virtuousgeek.org
Wed Apr 22 05:00:18 CEST 2009

On Tue, 21 Apr 2009 19:48:39 -0700
Eric Anholt <eric at anholt.net> wrote:

> On Tue, 2009-04-14 at 15:22 -0700, Jesse Barnes wrote:
> > Add a new page flipping ioctl to the i915 driver, using KMS
> > functionality.
> > 
> > Internally, the new flip ioctl will use the mode_set_base function,
> > which will simply update the front buffer pointer, taking care to
> > pin the new buffer and unpin the old one.  This means userspace
> > needs to create an FB id for the new front buffer prior to calling
> > in.
> > 
> > The flip will take place at the next vblank period automatically
> > (since the display base regs are double buffered), and any drawing
> > to a buffer with a pending flip will be blocked at execbuf time
> > until the next vblank interrupt fires and runs its completion
> > handler.
> What's ensuring that the rendering is complete before you queue the
> flip to the new buffer?  The lock breaking in list walking at idle is
> also making me uncomfortable.

Well we move it to the GTT domain before trying to flip it, is that not
sufficient?  As for the lock breaking, I may have screwed something up
with that change (there was code motion so I had to re-patch that
part), so please take a close look, there may be a better way to clean
it up.

Jesse Barnes, Intel Open Source Technology Center

More information about the Intel-gfx mailing list