All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] drm/i915: Shortcut readiness to reset check
@ 2019-04-12 15:37 Mika Kuoppala
  2019-04-12 15:37 ` [PATCH 2/3] drm/i915: Handle catastrophic error on engine reset Mika Kuoppala
                   ` (5 more replies)
  0 siblings, 6 replies; 12+ messages in thread
From: Mika Kuoppala @ 2019-04-12 15:37 UTC (permalink / raw)
  To: intel-gfx; +Cc: Chris

If the engine says it is ready for reset, it is ready
so avoid further dancing and proceed.

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

diff --git a/drivers/gpu/drm/i915/i915_reset.c b/drivers/gpu/drm/i915/i915_reset.c
index 68875ba43b8d..cde1a5309336 100644
--- a/drivers/gpu/drm/i915/i915_reset.c
+++ b/drivers/gpu/drm/i915/i915_reset.c
@@ -490,8 +490,13 @@ static int gen11_reset_engines(struct drm_i915_private *i915,
 static int gen8_engine_reset_prepare(struct intel_engine_cs *engine)
 {
 	struct intel_uncore *uncore = engine->uncore;
+	u32 ctl;
 	int ret;
 
+	ctl = intel_uncore_read_fw(uncore, RING_RESET_CTL(engine->mmio_base));
+	if (ctl & RESET_CTL_READY_TO_RESET)
+		return 0;
+
 	intel_uncore_write_fw(uncore,
 			      RING_RESET_CTL(engine->mmio_base),
 			      _MASKED_BIT_ENABLE(RESET_CTL_REQUEST_RESET));
-- 
2.17.1

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

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

end of thread, other threads:[~2019-04-12 19:38 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-12 15:37 [PATCH 1/3] drm/i915: Shortcut readiness to reset check Mika Kuoppala
2019-04-12 15:37 ` [PATCH 2/3] drm/i915: Handle catastrophic error on engine reset Mika Kuoppala
2019-04-12 15:49   ` Chris Wilson
2019-04-12 15:58     ` Mika Kuoppala
2019-04-12 15:37 ` [PATCH 3/3] drm/i915: Log catastrophic errors on gen11 Mika Kuoppala
2019-04-12 15:42   ` Chris Wilson
2019-04-12 15:47     ` Mika Kuoppala
2019-04-12 15:53       ` Chris Wilson
2019-04-12 15:51 ` [PATCH 1/3] drm/i915: Shortcut readiness to reset check Chris Wilson
2019-04-12 15:54 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/3] " Patchwork
2019-04-12 16:32 ` ✓ Fi.CI.BAT: success " Patchwork
2019-04-12 19:38 ` ✓ Fi.CI.IGT: " Patchwork

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.