Skip to content

Commit

Permalink
drm/i915: Don't ban default context when stop_rings!=0
Browse files Browse the repository at this point in the history
If we've explicitly stopped the rings for testing purposes, don't ban
the default context. Fixes kms_flip hang tests.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Acked-by: Mika Kuoppala <mika.kuoppala@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
  • Loading branch information
Ville Syrjälä authored and Daniel Vetter committed Mar 5, 2014
1 parent f103fc7 commit ccc7bed
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions drivers/gpu/drm/i915/i915_gem.c
Original file line number Diff line number Diff line change
Expand Up @@ -2255,14 +2255,13 @@ static bool i915_context_is_banned(struct drm_i915_private *dev_priv,
return true;

if (elapsed <= DRM_I915_CTX_BAN_PERIOD) {
if (dev_priv->gpu_error.stop_rings == 0 &&
i915_gem_context_is_default(ctx)) {
DRM_ERROR("gpu hanging too fast, banning!\n");
} else {
if (!i915_gem_context_is_default(ctx)) {
DRM_DEBUG("context hanging too fast, banning!\n");
return true;
} else if (dev_priv->gpu_error.stop_rings == 0) {
DRM_ERROR("gpu hanging too fast, banning!\n");
return true;
}

return true;
}

return false;
Expand Down

0 comments on commit ccc7bed

Please sign in to comment.