]> git.karo-electronics.de Git - linux-beck.git/commitdiff
drm/i915: Disable hangcheck when wedged
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 22 Nov 2016 14:41:19 +0000 (14:41 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Tue, 22 Nov 2016 17:42:17 +0000 (17:42 +0000)
If the gpu reset fails and the machine is terminally wedged, further
hangchecks achieve nothing but noise. Disable them, with a corollary
that we re-enable hangchecking after a successful GPU reset in case the
user is artificially bringing the machine back to life through the debug
interface.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20161122144121.7379-2-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/intel_hangcheck.c

index ff13503eae08d86ecfdd315ac256a5eda6cf05eb..b893e67b48970ae7f5ea6ab8664c9574b69abb21 100644 (file)
@@ -1822,6 +1822,8 @@ void i915_reset(struct drm_i915_private *dev_priv)
                goto error;
        }
 
+       i915_queue_hangcheck(dev_priv);
+
 wakeup:
        wake_up_bit(&error->flags, I915_RESET_IN_PROGRESS);
        return;
index c03db022a6d8f8ec1934e67a3c6ef5408632d3da..f05971f5586f22f8c1abfef378858e936816da02 100644 (file)
@@ -434,6 +434,9 @@ static void i915_hangcheck_elapsed(struct work_struct *work)
        if (!READ_ONCE(dev_priv->gt.awake))
                return;
 
+       if (i915_terminally_wedged(&dev_priv->gpu_error))
+               return;
+
        /* As enabling the GPU requires fairly extensive mmio access,
         * periodically arm the mmio checker to see if we are triggering
         * any invalid access.