* [Intel-gfx] [CI] drm/i915/gt: Protect execlists_hold/unhold from new waiters
@ 2020-02-07 11:02 Chris Wilson
2020-02-07 13:23 ` [Intel-gfx] ✗ Fi.CI.BAT: failure for " Patchwork
0 siblings, 1 reply; 2+ messages in thread
From: Chris Wilson @ 2020-02-07 11:02 UTC (permalink / raw)
To: intel-gfx
As we may add new waiters to a request as it is being run, we need to
mark the list iteration as being safe for concurrent addition.
v2: Mika spotted that we used the same trick for signalers_list, so warn
the compiler about the lockless walk there as well.
Fixes: 32ff621fd744 ("drm/i915/gt: Allow temporary suspension of inflight requests")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
---
drivers/gpu/drm/i915/gt/intel_lrc.c | 11 ++++++++---
drivers/gpu/drm/i915/i915_scheduler.c | 2 +-
2 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.c b/drivers/gpu/drm/i915/gt/intel_lrc.c
index b350e01d86d2..ed1e4d883d47 100644
--- a/drivers/gpu/drm/i915/gt/intel_lrc.c
+++ b/drivers/gpu/drm/i915/gt/intel_lrc.c
@@ -1620,6 +1620,11 @@ last_active(const struct intel_engine_execlists *execlists)
&(rq__)->sched.waiters_list, \
wait_link)
+#define for_each_signaler(p__, rq__) \
+ list_for_each_entry_lockless(p__, \
+ &(rq__)->sched.signalers_list, \
+ signal_link)
+
static void defer_request(struct i915_request *rq, struct list_head * const pl)
{
LIST_HEAD(list);
@@ -2378,7 +2383,7 @@ static void __execlists_hold(struct i915_request *rq)
list_move_tail(&rq->sched.link, &rq->engine->active.hold);
i915_request_set_hold(rq);
- list_for_each_entry(p, &rq->sched.waiters_list, wait_link) {
+ for_each_waiter(p, rq) {
struct i915_request *w =
container_of(p->waiter, typeof(*w), sched);
@@ -2464,7 +2469,7 @@ static bool hold_request(const struct i915_request *rq)
* If one of our ancestors is on hold, we must also be on hold,
* otherwise we will bypass it and execute before it.
*/
- list_for_each_entry(p, &rq->sched.signalers_list, signal_link) {
+ for_each_signaler(p, rq) {
const struct i915_request *s =
container_of(p->signaler, typeof(*s), sched);
@@ -2496,7 +2501,7 @@ static void __execlists_unhold(struct i915_request *rq)
RQ_TRACE(rq, "hold release\n");
/* Also release any children on this engine that are ready */
- list_for_each_entry(p, &rq->sched.waiters_list, wait_link) {
+ for_each_waiter(p, rq) {
struct i915_request *w =
container_of(p->waiter, typeof(*w), sched);
diff --git a/drivers/gpu/drm/i915/i915_scheduler.c b/drivers/gpu/drm/i915/i915_scheduler.c
index 34b654b4e58a..e19a37a83397 100644
--- a/drivers/gpu/drm/i915/i915_scheduler.c
+++ b/drivers/gpu/drm/i915/i915_scheduler.c
@@ -433,7 +433,7 @@ bool __i915_sched_node_add_dependency(struct i915_sched_node *node,
node->flags |= I915_SCHED_HAS_SEMAPHORE_CHAIN;
/* All set, now publish. Beware the lockless walkers. */
- list_add(&dep->signal_link, &node->signalers_list);
+ list_add_rcu(&dep->signal_link, &node->signalers_list);
list_add_rcu(&dep->wait_link, &signal->waiters_list);
/*
--
2.25.0
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [Intel-gfx] ✗ Fi.CI.BAT: failure for drm/i915/gt: Protect execlists_hold/unhold from new waiters
2020-02-07 11:02 [Intel-gfx] [CI] drm/i915/gt: Protect execlists_hold/unhold from new waiters Chris Wilson
@ 2020-02-07 13:23 ` Patchwork
0 siblings, 0 replies; 2+ messages in thread
From: Patchwork @ 2020-02-07 13:23 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: drm/i915/gt: Protect execlists_hold/unhold from new waiters
URL : https://patchwork.freedesktop.org/series/73133/
State : failure
== Summary ==
CI Bug Log - changes from CI_DRM_7885 -> Patchwork_16477
====================================================
Summary
-------
**FAILURE**
Serious unknown changes coming with Patchwork_16477 absolutely need to be
verified manually.
If you think the reported changes have nothing to do with the changes
introduced in Patchwork_16477, please notify your bug team to allow them
to document this new failure mode, which will reduce false positives in CI.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/index.html
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_16477:
### IGT changes ###
#### Possible regressions ####
* igt@gem_exec_suspend@basic-s4-devices:
- fi-icl-dsi: [PASS][1] -> [INCOMPLETE][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-icl-dsi/igt@gem_exec_suspend@basic-s4-devices.html
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-icl-dsi/igt@gem_exec_suspend@basic-s4-devices.html
Known issues
------------
Here are the changes found in Patchwork_16477 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@i915_pm_rpm@basic-pci-d3-state:
- fi-skl-6770hq: [PASS][3] -> [INCOMPLETE][4] ([i915#151])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-skl-6770hq/igt@i915_pm_rpm@basic-pci-d3-state.html
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-skl-6770hq/igt@i915_pm_rpm@basic-pci-d3-state.html
* igt@i915_selftest@live_gem_contexts:
- fi-cfl-8700k: [PASS][5] -> [INCOMPLETE][6] ([i915#424])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-cfl-8700k/igt@i915_selftest@live_gem_contexts.html
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-cfl-8700k/igt@i915_selftest@live_gem_contexts.html
* igt@i915_selftest@live_gtt:
- fi-glk-dsi: [PASS][7] -> [TIMEOUT][8] ([fdo#112271] / [i915#690])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-glk-dsi/igt@i915_selftest@live_gtt.html
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-glk-dsi/igt@i915_selftest@live_gtt.html
#### Possible fixes ####
* igt@gem_close_race@basic-threads:
- fi-byt-n2820: [INCOMPLETE][9] ([i915#45]) -> [PASS][10]
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-byt-n2820/igt@gem_close_race@basic-threads.html
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-byt-n2820/igt@gem_close_race@basic-threads.html
* igt@gem_exec_suspend@basic-s0:
- fi-cml-s: [FAIL][11] ([fdo#103375]) -> [PASS][12]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-cml-s/igt@gem_exec_suspend@basic-s0.html
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-cml-s/igt@gem_exec_suspend@basic-s0.html
* igt@i915_selftest@live_blt:
- fi-hsw-4770: [DMESG-FAIL][13] ([i915#553] / [i915#725]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-hsw-4770/igt@i915_selftest@live_blt.html
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-hsw-4770/igt@i915_selftest@live_blt.html
#### Warnings ####
* igt@gem_exec_suspend@basic-s3:
- fi-cml-s: [FAIL][15] ([fdo#103375]) -> [INCOMPLETE][16] ([i915#1078] / [i915#283])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-cml-s/igt@gem_exec_suspend@basic-s3.html
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-cml-s/igt@gem_exec_suspend@basic-s3.html
* igt@i915_selftest@live_blt:
- fi-ivb-3770: [DMESG-FAIL][17] ([i915#725]) -> [DMESG-FAIL][18] ([i915#563])
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7885/fi-ivb-3770/igt@i915_selftest@live_blt.html
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/fi-ivb-3770/igt@i915_selftest@live_blt.html
[fdo#103375]: https://bugs.freedesktop.org/show_bug.cgi?id=103375
[fdo#112271]: https://bugs.freedesktop.org/show_bug.cgi?id=112271
[i915#1078]: https://gitlab.freedesktop.org/drm/intel/issues/1078
[i915#151]: https://gitlab.freedesktop.org/drm/intel/issues/151
[i915#283]: https://gitlab.freedesktop.org/drm/intel/issues/283
[i915#424]: https://gitlab.freedesktop.org/drm/intel/issues/424
[i915#45]: https://gitlab.freedesktop.org/drm/intel/issues/45
[i915#553]: https://gitlab.freedesktop.org/drm/intel/issues/553
[i915#563]: https://gitlab.freedesktop.org/drm/intel/issues/563
[i915#690]: https://gitlab.freedesktop.org/drm/intel/issues/690
[i915#725]: https://gitlab.freedesktop.org/drm/intel/issues/725
Participating hosts (53 -> 45)
------------------------------
Missing (8): fi-ilk-m540 fi-bdw-5557u fi-hsw-4200u fi-bsw-cyan fi-ctg-p8600 fi-whl-u fi-byt-clapper fi-bdw-samus
Build changes
-------------
* CI: CI-20190529 -> None
* Linux: CI_DRM_7885 -> Patchwork_16477
CI-20190529: 20190529
CI_DRM_7885: fc2806bc441bfc6b44cf4713f3c6b820d73c3534 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5424: 092230f1a5297ca8b1fbff8da7f08bac7aa05df1 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_16477: b240b7c4829c12446b1c5896e451e674c394151a @ git://anongit.freedesktop.org/gfx-ci/linux
== Linux commits ==
b240b7c4829c drm/i915/gt: Protect execlists_hold/unhold from new waiters
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_16477/index.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-02-07 13:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-07 11:02 [Intel-gfx] [CI] drm/i915/gt: Protect execlists_hold/unhold from new waiters Chris Wilson
2020-02-07 13:23 ` [Intel-gfx] ✗ Fi.CI.BAT: failure for " 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.