[Intel-gfx] [PATCH 6/8] drm/i915: Add bind/unbind object functions to VM
Daniel Vetter
daniel at ffwll.ch
Thu Sep 12 00:49:41 CEST 2013
On Wed, Sep 11, 2013 at 11:25:50PM +0100, Chris Wilson wrote:
> On Wed, Sep 11, 2013 at 02:57:53PM -0700, Ben Widawsky wrote:
> > From: Ben Widawsky <ben at bwidawsk.net>
> >
> > As we plumb the code with more VM information, it has become more
> > obvious that the easiest way to deal with bind and unbind is to simply
> > put the function pointers in the vm, and let those choose the correct
> > way to handle the page table updates. This change allows many places in
> > the code to simply be vm->bind, and not have to worry about
> > distinguishing PPGTT vs GGTT.
> >
> > Notice that this patch has no impact on functionality. I've decided to
> > save the actual change until the next patch because I think it's easier
> > to review that way. I'm happy to squash the two, or let Daniel do it on
> > merge.
>
> Oh, this is disappointing. The GLOBAL_BIND flag is a let down. Is there
> any way we can have the aliasing_ppgtt as a separate vm and so keep the
> purity?
The problem is that the vm manages the address space, and it's paramount
on snb that we can line up objects into both the ggtt and ppgtt at will at
the exact same offset. Otherwise at least pipe control w/a won't work and
reading between bspec gives more promises of things that will break.
Adding complex logic to punt out such holes doesn't sound cleaner nor
simpler than the magic flags we're using here. And I have to admit that I
couldn't come up with another idea (besides flat-out killing aliasing
ppgtt on snb). So ideas welcome ...
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
More information about the Intel-gfx
mailing list