[Intel-gfx] [PATCH 1/5] drm/i915/gt: Wait for new requests in intel_gt_retire_requests()

Chris Wilson chris at chris-wilson.co.uk
Fri Nov 15 12:49:05 UTC 2019


Quoting Tvrtko Ursulin (2019-11-15 12:45:52)
> 
> On 14/11/2019 22:57, Chris Wilson wrote:
> > Our callers fall into two categories, those passing timeout=0 who just
> > want to flush request retirements and those passing a timeout that need
> > to wait for submission completion (e.g. intel_gt_wait_for_idle()).
> > Currently, we only wait for a snapshot of timelines at the start of the
> > wait (but there was an expection that new requests would cause timelines
> 
> expectation? exception?
expectation

> > to appear at the end). However, our callers, such as
> > intel_gt_wait_for_idle() before suspend, do require us to wait for the
> > power management requests emitted by retirement as well. If we don't,
> > then it takes an extra second or two for the background worker to flush
> > the queue and mark the GT as idle.
> 
> So with this change wait_for_idle waits for the kernel context to get 
> retired as well. And you say that's faster by a second or two? Which 
> flush gets so much slower, I mean from where, if we don't wait here?

intel_gt_pm_wait_for_idle() (so i915_gem_suspend, and selftests that
exercise those same paths) then has to wait for the background retire
worker to flush the final requests and drop the wakeref.
-Chris


More information about the Intel-gfx mailing list