[PATCH] drm/i915: extract object unplug code from busy/wait_timeout ioctl

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 30 May 2012 23:15:39 +0200, Daniel Vetter <daniel at ffwll.ch> wrote:
> On Wed, May 30, 2012 at 01:41:28PM -0700, Ben Widawsky wrote:
> > On Wed, 30 May 2012 20:21:33 +0200
> > Daniel Vetter <daniel.vetter at ffwll.ch> wrote:
> > > I've tested this by pimping the i-g-t test some more and also checking
> > > the polling behviour of the wait_rendering_timeout ioctl versus what
> > > busy_ioctl returns.
> > > 
> > > Signed-Off-by: Daniel Vetter <daniel.vetter at ffwll.ch>
> > > ---
> > >  drivers/gpu/drm/i915/i915_gem.c |   61 ++++++++++++++++++--------------------
> > >  1 files changed, 29 insertions(+), 32 deletions(-)
> > > 
> > > diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
> > > index d2eaa00..521e294 100644
> > > --- a/drivers/gpu/drm/i915/i915_gem.c
> > > +++ b/drivers/gpu/drm/i915/i915_gem.c
> > > @@ -2000,6 +2000,31 @@ i915_gem_object_wait_rendering(struct drm_i915_gem_object *obj)
> > >  }
> > >  
> > >  /**
> > > + * Ensures that an object will eventually get non-busy by flushing any required
> > > + * write domains, emitting any outstanding lazy request and retiring and
> > > + * completed requests. The unplug moniker is stolen from the linux block layer.
> > > + */
> > I'd prefer something like, "unbusy" but whatever.
> 
> Considered and I've thought that's not a proper word. And unbusy isn't
> quite correct either, because this only ensures that the object will get
> unbusy eventually, if you keep on calling this function (due to the
> retire_request in there). And _eventually_unbusy_object sounds horrible to
> me. I admit that unplug is a misdenomer, too, but I lack good ideas.

i965_gem_object_check_retired()?  Just about anything would be better
than unplug.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20120531/bb79ee3f/attachment.pgp>


[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux