Now that the code is getting simpler, we can reduce the indentation when waiting for the global_seqno. Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@xxxxxxxxx> --- drivers/gpu/drm/i915/i915_gem_request.c | 39 +++++++++++++++------------------ 1 file changed, 18 insertions(+), 21 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_gem_request.c b/drivers/gpu/drm/i915/i915_gem_request.c index eaa333a35f7c..bb29255dd3a1 100644 --- a/drivers/gpu/drm/i915/i915_gem_request.c +++ b/drivers/gpu/drm/i915/i915_gem_request.c @@ -1089,32 +1089,29 @@ long i915_wait_request(struct drm_i915_gem_request *req, intel_wait_init(&wait); restart: - if (!intel_wait_update_request(&wait, req)) { - do { - set_current_state(state); - - if (intel_wait_update_request(&wait, req)) - break; + do { + set_current_state(state); + if (intel_wait_update_request(&wait, req)) + break; - if (flags & I915_WAIT_LOCKED && - __i915_wait_request_check_and_reset(req)) - continue; + if (flags & I915_WAIT_LOCKED && + __i915_wait_request_check_and_reset(req)) + continue; - if (signal_pending_state(state, current)) { - timeout = -ERESTARTSYS; - goto complete; - } + if (signal_pending_state(state, current)) { + timeout = -ERESTARTSYS; + goto complete; + } - if (!timeout) { - timeout = -ETIME; - goto complete; - } + if (!timeout) { + timeout = -ETIME; + goto complete; + } - timeout = io_schedule_timeout(timeout); - } while (1); + timeout = io_schedule_timeout(timeout); + } while (1); - GEM_BUG_ON(!intel_wait_has_seqno(&wait)); - } + GEM_BUG_ON(!intel_wait_has_seqno(&wait)); GEM_BUG_ON(!i915_sw_fence_signaled(&req->submit)); /* Optimistic short spin before touching IRQs */ -- 2.11.0 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx