* [PATCH 1/3] drm/i915: Check execlist/ring status during hangcheck
@ 2017-07-03 13:04 Chris Wilson
2017-07-03 13:04 ` [PATCH 2/3] drm/i915: Check the execlist queue for pending requests before declaring idle Chris Wilson
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Chris Wilson @ 2017-07-03 13:04 UTC (permalink / raw)
To: intel-gfx
Before we declare an engine as idle, check if there are any pending
execlist context-switches and if the ring itself reports as idle.
Otherwise, we may be left in a situation where we miss a crucial
execlist event (or something more sinister) yet the requests complete.
Since the seqno write happens, we believe the engine to be truly idle.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
drivers/gpu/drm/i915/intel_hangcheck.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/intel_hangcheck.c b/drivers/gpu/drm/i915/intel_hangcheck.c
index 9b0ece427bdc..d9d87d96fb69 100644
--- a/drivers/gpu/drm/i915/intel_hangcheck.c
+++ b/drivers/gpu/drm/i915/intel_hangcheck.c
@@ -324,7 +324,7 @@ hangcheck_get_action(struct intel_engine_cs *engine,
if (engine->hangcheck.seqno != hc->seqno)
return ENGINE_ACTIVE_SEQNO;
- if (i915_seqno_passed(hc->seqno, intel_engine_last_submit(engine)))
+ if (intel_engine_is_idle(engine))
return ENGINE_IDLE;
return engine_stuck(engine, hc->acthd);
--
2.13.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/3] drm/i915: Check the execlist queue for pending requests before declaring idle
2017-07-03 13:04 [PATCH 1/3] drm/i915: Check execlist/ring status during hangcheck Chris Wilson
@ 2017-07-03 13:04 ` Chris Wilson
2017-07-03 13:04 ` [PATCH 3/3] drm/i915: Wake up waiters after setting the WEDGED bit Chris Wilson
2017-07-03 13:28 ` ✓ Fi.CI.BAT: success for series starting with [1/3] drm/i915: Check execlist/ring status during hangcheck Patchwork
2 siblings, 0 replies; 4+ messages in thread
From: Chris Wilson @ 2017-07-03 13:04 UTC (permalink / raw)
To: intel-gfx
Including a check against the execlist queue before calling the engine
idle and passing hangcheck.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
drivers/gpu/drm/i915/intel_engine_cs.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/gpu/drm/i915/intel_engine_cs.c b/drivers/gpu/drm/i915/intel_engine_cs.c
index a55cd72aeeff..00682c7aae9c 100644
--- a/drivers/gpu/drm/i915/intel_engine_cs.c
+++ b/drivers/gpu/drm/i915/intel_engine_cs.c
@@ -1282,6 +1282,10 @@ bool intel_engine_is_idle(struct intel_engine_cs *engine)
if (port_request(&engine->execlist_port[0]))
return false;
+ /* ELSP is empty, but there are ready requests? */
+ if (READ_ONCE(engine->execlist_first))
+ return false;
+
/* Ring stopped? */
if (!ring_is_idle(engine))
return false;
--
2.13.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 3/3] drm/i915: Wake up waiters after setting the WEDGED bit
2017-07-03 13:04 [PATCH 1/3] drm/i915: Check execlist/ring status during hangcheck Chris Wilson
2017-07-03 13:04 ` [PATCH 2/3] drm/i915: Check the execlist queue for pending requests before declaring idle Chris Wilson
@ 2017-07-03 13:04 ` Chris Wilson
2017-07-03 13:28 ` ✓ Fi.CI.BAT: success for series starting with [1/3] drm/i915: Check execlist/ring status during hangcheck Patchwork
2 siblings, 0 replies; 4+ messages in thread
From: Chris Wilson @ 2017-07-03 13:04 UTC (permalink / raw)
To: intel-gfx
After setting the WEDGED bit, make sure that we do wake up waiters as
they may not be waiting for a request completion yet, just for its
execution.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
drivers/gpu/drm/i915/i915_gem.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 1b2dfa8bdeef..b4504cc041d0 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -3093,10 +3093,12 @@ static int __i915_gem_set_wedged_BKL(void *data)
struct intel_engine_cs *engine;
enum intel_engine_id id;
- set_bit(I915_WEDGED, &i915->gpu_error.flags);
for_each_engine(engine, i915, id)
engine_set_wedged(engine);
+ set_bit(I915_WEDGED, &i915->gpu_error.flags);
+ wake_up_all(&i915->gpu_error.reset_queue);
+
return 0;
}
--
2.13.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 4+ messages in thread
* ✓ Fi.CI.BAT: success for series starting with [1/3] drm/i915: Check execlist/ring status during hangcheck
2017-07-03 13:04 [PATCH 1/3] drm/i915: Check execlist/ring status during hangcheck Chris Wilson
2017-07-03 13:04 ` [PATCH 2/3] drm/i915: Check the execlist queue for pending requests before declaring idle Chris Wilson
2017-07-03 13:04 ` [PATCH 3/3] drm/i915: Wake up waiters after setting the WEDGED bit Chris Wilson
@ 2017-07-03 13:28 ` Patchwork
2 siblings, 0 replies; 4+ messages in thread
From: Patchwork @ 2017-07-03 13:28 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: series starting with [1/3] drm/i915: Check execlist/ring status during hangcheck
URL : https://patchwork.freedesktop.org/series/26747/
State : success
== Summary ==
Series 26747v1 Series without cover letter
https://patchwork.freedesktop.org/api/1.0/series/26747/revisions/1/mbox/
Test gem_exec_flush:
Subgroup basic-batch-kernel-default-uc:
pass -> FAIL (fi-snb-2600) fdo#100007
Test gem_exec_suspend:
Subgroup basic-s4-devices:
dmesg-warn -> PASS (fi-kbl-7560u) fdo#100125
Test gem_ringfill:
Subgroup basic-default-hang:
dmesg-warn -> INCOMPLETE (fi-blb-e6850) fdo#101600 +1
fdo#100007 https://bugs.freedesktop.org/show_bug.cgi?id=100007
fdo#100125 https://bugs.freedesktop.org/show_bug.cgi?id=100125
fdo#101600 https://bugs.freedesktop.org/show_bug.cgi?id=101600
fi-bdw-5557u total:279 pass:264 dwarn:0 dfail:0 fail:3 skip:11 time:441s
fi-bdw-gvtdvm total:279 pass:257 dwarn:8 dfail:0 fail:0 skip:14 time:423s
fi-blb-e6850 total:146 pass:113 dwarn:0 dfail:0 fail:0 skip:32
fi-bsw-n3050 total:279 pass:239 dwarn:0 dfail:0 fail:3 skip:36 time:522s
fi-bxt-j4205 total:279 pass:256 dwarn:0 dfail:0 fail:3 skip:19 time:504s
fi-byt-j1900 total:279 pass:250 dwarn:1 dfail:0 fail:3 skip:24 time:484s
fi-byt-n2820 total:279 pass:246 dwarn:1 dfail:0 fail:3 skip:28 time:477s
fi-glk-2a total:279 pass:256 dwarn:0 dfail:0 fail:3 skip:19 time:587s
fi-hsw-4770 total:279 pass:259 dwarn:0 dfail:0 fail:3 skip:16 time:428s
fi-hsw-4770r total:279 pass:259 dwarn:0 dfail:0 fail:3 skip:16 time:413s
fi-ilk-650 total:279 pass:225 dwarn:0 dfail:0 fail:3 skip:50 time:415s
fi-ivb-3520m total:279 pass:257 dwarn:0 dfail:0 fail:3 skip:18 time:493s
fi-ivb-3770 total:279 pass:257 dwarn:0 dfail:0 fail:3 skip:18 time:468s
fi-kbl-7500u total:279 pass:257 dwarn:0 dfail:0 fail:3 skip:18 time:456s
fi-kbl-7560u total:279 pass:265 dwarn:0 dfail:0 fail:3 skip:10 time:559s
fi-kbl-r total:279 pass:256 dwarn:1 dfail:0 fail:3 skip:18 time:566s
fi-pnv-d510 total:146 pass:112 dwarn:0 dfail:0 fail:0 skip:33
fi-skl-6260u total:279 pass:265 dwarn:0 dfail:0 fail:3 skip:10 time:447s
fi-skl-6700hq total:279 pass:219 dwarn:1 dfail:0 fail:33 skip:24 time:305s
fi-skl-6700k total:279 pass:257 dwarn:0 dfail:0 fail:3 skip:18 time:461s
fi-skl-6770hq total:279 pass:265 dwarn:0 dfail:0 fail:3 skip:10 time:469s
fi-skl-gvtdvm total:279 pass:266 dwarn:0 dfail:0 fail:0 skip:13 time:439s
fi-snb-2520m total:279 pass:247 dwarn:0 dfail:0 fail:3 skip:28 time:542s
fi-snb-2600 total:279 pass:245 dwarn:0 dfail:0 fail:4 skip:29 time:401s
53a8e90f14a257e7241f8dac9f54f279dddce752 drm-tip: 2017y-07m-03d-12h-10m-14s UTC integration manifest
88ce034 drm/i915: Wake up waiters after setting the WEDGED bit
fe4f744 drm/i915: Check the execlist queue for pending requests before declaring idle
7a1739f drm/i915: Check execlist/ring status during hangcheck
== Logs ==
For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_5092/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-07-03 13:28 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-03 13:04 [PATCH 1/3] drm/i915: Check execlist/ring status during hangcheck Chris Wilson
2017-07-03 13:04 ` [PATCH 2/3] drm/i915: Check the execlist queue for pending requests before declaring idle Chris Wilson
2017-07-03 13:04 ` [PATCH 3/3] drm/i915: Wake up waiters after setting the WEDGED bit Chris Wilson
2017-07-03 13:28 ` ✓ Fi.CI.BAT: success for series starting with [1/3] drm/i915: Check execlist/ring status during hangcheck Patchwork
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).