All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Skip HW reinitialisation on resume if still wedged
@ 2017-10-15 14:30 Chris Wilson
  2017-10-15 14:37 ` [PATCH v2] " Chris Wilson
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Chris Wilson @ 2017-10-15 14:30 UTC (permalink / raw)
  To: intel-gfx

If we fail to recover the HW state upon resume (i.e. our attempt to
clear the wedged bit and reset during i915_gem_sanitize() fails), then
skip the HW restart inside i915_gem_init_hw(). We will ultimate do the
the HW restart when sucessfully unwedgeding and reseting the HW later,
but attempting to restore a wedged device upon resume is risky as the HW
is in an unknown state.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
---
 drivers/gpu/drm/i915/i915_gem.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index d9d39b309ce8..5993222c81ae 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -4835,6 +4835,10 @@ int i915_gem_init_hw(struct drm_i915_private *dev_priv)
 	init_unused_rings(dev_priv);
 
 	BUG_ON(!dev_priv->kernel_context);
+	if (i915_terminally_wedged(&dev_priv->gpu_error)) {
+		ret = -EIO;
+		goto out;
+	}
 
 	ret = i915_ppgtt_init_hw(dev_priv);
 	if (ret) {
-- 
2.15.0.rc0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-10-16 20:15 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-15 14:30 [PATCH] drm/i915: Skip HW reinitialisation on resume if still wedged Chris Wilson
2017-10-15 14:37 ` [PATCH v2] " Chris Wilson
2017-10-15 20:31   ` Chris Wilson
2017-10-16 14:24   ` Mika Kuoppala
2017-10-16 14:28     ` Chris Wilson
2017-10-16 15:30   ` Mika Kuoppala
2017-10-16 20:15     ` Chris Wilson
2017-10-15 14:53 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-10-15 15:12 ` ✓ Fi.CI.BAT: success for drm/i915: Skip HW reinitialisation on resume if still wedged (rev2) Patchwork
2017-10-15 16:10 ` ✓ Fi.CI.IGT: " Patchwork
2017-10-16 15:29 ` [PATCH] drm/i915: Skip HW reinitialisation on resume if still wedged Mika Kuoppala

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.