[Intel-gfx] [PATCH 11/27] drm/i915: Merge wait_for_timelines with retire_request

Chris Wilson chris at chris-wilson.co.uk
Wed Sep 25 10:54:12 UTC 2019


Quoting Tvrtko Ursulin (2019-09-25 11:47:35)
> 
> On 25/09/2019 11:01, Chris Wilson wrote:
> > -bool i915_retire_requests(struct drm_i915_private *i915)
> > +long i915_retire_requests_timeout(struct drm_i915_private *i915, long timeout)
> >   {
> >       struct intel_gt_timelines *timelines = &i915->gt.timelines;
> >       struct intel_timeline *tl, *tn;
> > +     unsigned long active_count = 0;
> >       unsigned long flags;
> > +     bool interruptible;
> >       LIST_HEAD(free);
> >   
> > +     interruptible = true;
> > +     if (timeout < 0)
> > +             timeout = -timeout, interruptible = false;
> 
> Slightly uneasy about the negative trick but alternatives which came to 
> mind of or-ing the negative bit or wrapper for passing in the 
> (non-)interruptible(timeout) do not sound so hot either.

Queasy feeling concurred. Our mission is not to have any
non-interruptible sleeps, but if we do we'll have to add unsigned flags
back. :|
-Chris


More information about the Intel-gfx mailing list