summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/i915_gem_request.c
diff options
context:
space:
mode:
authorMika Kuoppala <mika.kuoppala@linux.intel.com>2016-11-16 17:20:31 +0200
committerMika Kuoppala <mika.kuoppala@intel.com>2016-11-21 14:36:40 +0200
commite5e1fc47eac842daeccc2dd125437f43e0271032 (patch)
tree0e4082b4481d46d2887082d9d8dca7eafa42da51 /drivers/gpu/drm/i915/i915_gem_request.c
parent3fe3b030bd2d7a51c12aa6fe0e5178b9f1a726ec (diff)
drm/i915: Use request retirement as context progress
As hangcheck score was removed, the active decay of score was removed also. This removed feature for hangcheck to detect if the gpu client was accidentally or maliciously causing intermittent hangs. Reinstate the scoring as a per context property, so that if one context starts to act unfavourably, ban it. v2: ban_period_secs as a gate to score check (Chris) v3: decay in proper spot. scores as tunables (Chris) Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem_request.c')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_request.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_request.c b/drivers/gpu/drm/i915/i915_gem_request.c
index 27e8f257fb39..60e63956ea19 100644
--- a/drivers/gpu/drm/i915/i915_gem_request.c
+++ b/drivers/gpu/drm/i915/i915_gem_request.c
@@ -263,6 +263,10 @@ static void i915_gem_request_retire(struct drm_i915_gem_request *request)
request->engine);
}
+ /* Retirement decays the ban score as it is a sign of ctx progress */
+ if (request->ctx->hang_stats.ban_score > 0)
+ request->ctx->hang_stats.ban_score--;
+
i915_gem_context_put(request->ctx);
dma_fence_signal(&request->fence);