All of lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-gfx] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-03  9:57 ` Chris Wilson
  0 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-03  9:57 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 59 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 59 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..f885f7fa3 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -336,6 +336,62 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +436,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

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

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

* [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-03  9:57 ` Chris Wilson
  0 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-03  9:57 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Tvrtko Ursulin, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 59 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 59 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..f885f7fa3 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -336,6 +336,62 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +436,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [Intel-gfx] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
  2020-12-03  9:57 ` [igt-dev] " Chris Wilson
@ 2020-12-03  9:59   ` Chris Wilson
  -1 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-03  9:59 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 60 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..18d5d1217 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+		gem_sync(i915, spin->handle);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +437,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

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

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

* [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-03  9:59   ` Chris Wilson
  0 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-03  9:59 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Tvrtko Ursulin, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 60 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..18d5d1217 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+		gem_sync(i915, spin->handle);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +437,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✓ Fi.CI.BAT: success for i915/gem_ctx_exec: Exercise execution along context while closing it (rev2)
  2020-12-03  9:57 ` [igt-dev] " Chris Wilson
  (?)
  (?)
@ 2020-12-03 11:21 ` Patchwork
  -1 siblings, 0 replies; 15+ messages in thread
From: Patchwork @ 2020-12-03 11:21 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev


[-- Attachment #1.1: Type: text/plain, Size: 3341 bytes --]

== Series Details ==

Series: i915/gem_ctx_exec: Exercise execution along context while closing it (rev2)
URL   : https://patchwork.freedesktop.org/series/84530/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_9432 -> IGTPW_5247
====================================================

Summary
-------

  **SUCCESS**

  No regressions found.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/index.html

Known issues
------------

  Here are the changes found in IGTPW_5247 that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@gem_ringfill@basic-all:
    - fi-tgl-y:           [PASS][1] -> [DMESG-WARN][2] ([i915#402]) +2 similar issues
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/fi-tgl-y/igt@gem_ringfill@basic-all.html
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/fi-tgl-y/igt@gem_ringfill@basic-all.html

  * igt@i915_pm_rpm@module-reload:
    - fi-kbl-guc:         [PASS][3] -> [FAIL][4] ([i915#579])
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/fi-kbl-guc/igt@i915_pm_rpm@module-reload.html
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/fi-kbl-guc/igt@i915_pm_rpm@module-reload.html

  
#### Possible fixes ####

  * igt@core_hotunplug@unbind-rebind:
    - fi-apl-guc:         [INCOMPLETE][5] -> [PASS][6]
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/fi-apl-guc/igt@core_hotunplug@unbind-rebind.html
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/fi-apl-guc/igt@core_hotunplug@unbind-rebind.html

  * igt@debugfs_test@read_all_entries:
    - {fi-kbl-7560u}:     [INCOMPLETE][7] ([i915#2417]) -> [PASS][8]
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/fi-kbl-7560u/igt@debugfs_test@read_all_entries.html
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/fi-kbl-7560u/igt@debugfs_test@read_all_entries.html

  * igt@prime_self_import@basic-with_one_bo_two_files:
    - fi-tgl-y:           [DMESG-WARN][9] ([i915#402]) -> [PASS][10] +1 similar issue
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/fi-tgl-y/igt@prime_self_import@basic-with_one_bo_two_files.html
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/fi-tgl-y/igt@prime_self_import@basic-with_one_bo_two_files.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [i915#2417]: https://gitlab.freedesktop.org/drm/intel/issues/2417
  [i915#402]: https://gitlab.freedesktop.org/drm/intel/issues/402
  [i915#579]: https://gitlab.freedesktop.org/drm/intel/issues/579


Participating hosts (45 -> 40)
------------------------------

  Missing    (5): fi-ilk-m540 fi-hsw-4200u fi-bsw-cyan fi-dg1-1 fi-bdw-samus 


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_5878 -> IGTPW_5247

  CI-20190529: 20190529
  CI_DRM_9432: a7ed9b96ea3d9e89190a0cd08feb99e6b3e701a9 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_5247: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/index.html
  IGT_5878: e96c0d8e6952d892bcbbcdf004999880a4dfb42e @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools



== Testlist changes ==

+igt@gem_ctx_exec@basic-close-race

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/index.html

[-- Attachment #1.2: Type: text/html, Size: 4146 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✗ Fi.CI.IGT: failure for i915/gem_ctx_exec: Exercise execution along context while closing it (rev2)
  2020-12-03  9:57 ` [igt-dev] " Chris Wilson
                   ` (2 preceding siblings ...)
  (?)
@ 2020-12-03 16:10 ` Patchwork
  -1 siblings, 0 replies; 15+ messages in thread
From: Patchwork @ 2020-12-03 16:10 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev


[-- Attachment #1.1: Type: text/plain, Size: 17119 bytes --]

== Series Details ==

Series: i915/gem_ctx_exec: Exercise execution along context while closing it (rev2)
URL   : https://patchwork.freedesktop.org/series/84530/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_9432_full -> IGTPW_5247_full
====================================================

Summary
-------

  **FAILURE**

  Serious unknown changes coming with IGTPW_5247_full absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_5247_full, 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/IGTPW_5247/index.html

Possible new issues
-------------------

  Here are the unknown changes that may have been introduced in IGTPW_5247_full:

### IGT changes ###

#### Possible regressions ####

  * {igt@gem_ctx_exec@basic-close-race} (NEW):
    - shard-tglb:         NOTRUN -> [TIMEOUT][1]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb3/igt@gem_ctx_exec@basic-close-race.html
    - shard-glk:          NOTRUN -> [TIMEOUT][2]
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk9/igt@gem_ctx_exec@basic-close-race.html
    - shard-apl:          NOTRUN -> [FAIL][3]
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-apl3/igt@gem_ctx_exec@basic-close-race.html
    - shard-kbl:          NOTRUN -> [TIMEOUT][4]
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl1/igt@gem_ctx_exec@basic-close-race.html
    - shard-iclb:         NOTRUN -> [TIMEOUT][5]
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb1/igt@gem_ctx_exec@basic-close-race.html
    - shard-hsw:          NOTRUN -> [FAIL][6]
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw6/igt@gem_ctx_exec@basic-close-race.html
    - shard-snb:          NOTRUN -> [FAIL][7]
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-snb6/igt@gem_ctx_exec@basic-close-race.html

  * igt@gem_userptr_blits@stress-mm:
    - shard-hsw:          [PASS][8] -> [INCOMPLETE][9]
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw6/igt@gem_userptr_blits@stress-mm.html
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw7/igt@gem_userptr_blits@stress-mm.html

  
New tests
---------

  New tests have been introduced between CI_DRM_9432_full and IGTPW_5247_full:

### New IGT tests (1) ###

  * igt@gem_ctx_exec@basic-close-race:
    - Statuses : 3 fail(s) 4 timeout(s)
    - Exec time: [5.43, 120.96] s

  

Known issues
------------

  Here are the changes found in IGTPW_5247_full that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@gem_exec_whisper@basic-queues-all:
    - shard-glk:          [PASS][10] -> [DMESG-WARN][11] ([i915#118] / [i915#95]) +1 similar issue
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk1/igt@gem_exec_whisper@basic-queues-all.html
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk4/igt@gem_exec_whisper@basic-queues-all.html

  * igt@kms_flip@flip-vs-absolute-wf_vblank@a-edp1:
    - shard-tglb:         [PASS][12] -> [FAIL][13] ([i915#2122])
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb2/igt@kms_flip@flip-vs-absolute-wf_vblank@a-edp1.html
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb2/igt@kms_flip@flip-vs-absolute-wf_vblank@a-edp1.html

  * igt@kms_flip@flip-vs-expired-vblank-interruptible@b-hdmi-a1:
    - shard-glk:          [PASS][14] -> [FAIL][15] ([i915#79])
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk9/igt@kms_flip@flip-vs-expired-vblank-interruptible@b-hdmi-a1.html
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk5/igt@kms_flip@flip-vs-expired-vblank-interruptible@b-hdmi-a1.html

  * igt@kms_flip@flip-vs-suspend@a-dp1:
    - shard-apl:          [PASS][16] -> [INCOMPLETE][17] ([i915#2635])
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-apl7/igt@kms_flip@flip-vs-suspend@a-dp1.html
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-apl6/igt@kms_flip@flip-vs-suspend@a-dp1.html
    - shard-kbl:          [PASS][18] -> [INCOMPLETE][19] ([i915#155])
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-kbl6/igt@kms_flip@flip-vs-suspend@a-dp1.html
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl2/igt@kms_flip@flip-vs-suspend@a-dp1.html

  * igt@kms_flip@flip-vs-suspend@a-edp1:
    - shard-tglb:         [PASS][20] -> [DMESG-WARN][21] ([i915#1436] / [i915#1602] / [i915#1887] / [i915#2411])
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb3/igt@kms_flip@flip-vs-suspend@a-edp1.html
   [21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb5/igt@kms_flip@flip-vs-suspend@a-edp1.html
    - shard-iclb:         [PASS][22] -> [INCOMPLETE][23] ([i915#2483])
   [22]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb3/igt@kms_flip@flip-vs-suspend@a-edp1.html
   [23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb5/igt@kms_flip@flip-vs-suspend@a-edp1.html

  * igt@kms_flip@flip-vs-suspend@a-hdmi-a1:
    - shard-glk:          [PASS][24] -> [INCOMPLETE][25] ([i915#1982] / [i915#2635])
   [24]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk8/igt@kms_flip@flip-vs-suspend@a-hdmi-a1.html
   [25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk5/igt@kms_flip@flip-vs-suspend@a-hdmi-a1.html

  * igt@kms_flip@flip-vs-suspend@a-vga1:
    - shard-hsw:          [PASS][26] -> [INCOMPLETE][27] ([i915#2055] / [i915#2637])
   [26]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw6/igt@kms_flip@flip-vs-suspend@a-vga1.html
   [27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw2/igt@kms_flip@flip-vs-suspend@a-vga1.html

  * igt@kms_flip@flip-vs-suspend@b-edp1:
    - shard-tglb:         [PASS][28] -> [INCOMPLETE][29] ([i915#1436] / [i915#1798] / [i915#1982])
   [28]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb3/igt@kms_flip@flip-vs-suspend@b-edp1.html
   [29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb5/igt@kms_flip@flip-vs-suspend@b-edp1.html

  * igt@kms_psr@psr2_cursor_blt:
    - shard-iclb:         [PASS][30] -> [SKIP][31] ([fdo#109441])
   [30]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb2/igt@kms_psr@psr2_cursor_blt.html
   [31]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb4/igt@kms_psr@psr2_cursor_blt.html

  
#### Possible fixes ####

  * igt@gem_exec_reloc@basic-many-active@rcs0:
    - shard-hsw:          [FAIL][32] ([i915#2389]) -> [PASS][33]
   [32]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw7/igt@gem_exec_reloc@basic-many-active@rcs0.html
   [33]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw6/igt@gem_exec_reloc@basic-many-active@rcs0.html

  * igt@i915_pm_rpm@system-suspend-execbuf:
    - shard-iclb:         [SKIP][34] ([i915#579]) -> [PASS][35]
   [34]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb6/igt@i915_pm_rpm@system-suspend-execbuf.html
   [35]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb2/igt@i915_pm_rpm@system-suspend-execbuf.html
    - shard-kbl:          [SKIP][36] ([fdo#109271]) -> [PASS][37]
   [36]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-kbl4/igt@i915_pm_rpm@system-suspend-execbuf.html
   [37]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl3/igt@i915_pm_rpm@system-suspend-execbuf.html
    - shard-apl:          [SKIP][38] ([fdo#109271]) -> [PASS][39]
   [38]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-apl4/igt@i915_pm_rpm@system-suspend-execbuf.html
   [39]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-apl4/igt@i915_pm_rpm@system-suspend-execbuf.html
    - shard-tglb:         [SKIP][40] ([i915#579]) -> [PASS][41]
   [40]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb2/igt@i915_pm_rpm@system-suspend-execbuf.html
   [41]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb7/igt@i915_pm_rpm@system-suspend-execbuf.html
    - shard-glk:          [SKIP][42] ([fdo#109271]) -> [PASS][43]
   [42]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk3/igt@i915_pm_rpm@system-suspend-execbuf.html
   [43]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk3/igt@i915_pm_rpm@system-suspend-execbuf.html

  * igt@kms_fbcon_fbt@fbc-suspend:
    - shard-iclb:         [INCOMPLETE][44] ([i915#1185]) -> [PASS][45]
   [44]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb6/igt@kms_fbcon_fbt@fbc-suspend.html
   [45]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb1/igt@kms_fbcon_fbt@fbc-suspend.html
    - shard-apl:          [INCOMPLETE][46] ([i915#2635]) -> [PASS][47]
   [46]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-apl4/igt@kms_fbcon_fbt@fbc-suspend.html
   [47]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-apl6/igt@kms_fbcon_fbt@fbc-suspend.html
    - shard-glk:          [INCOMPLETE][48] ([i915#2635]) -> [PASS][49]
   [48]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk3/igt@kms_fbcon_fbt@fbc-suspend.html
   [49]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk1/igt@kms_fbcon_fbt@fbc-suspend.html
    - shard-tglb:         [INCOMPLETE][50] ([i915#1436] / [i915#1602] / [i915#1887] / [i915#2411] / [i915#456]) -> [PASS][51]
   [50]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb2/igt@kms_fbcon_fbt@fbc-suspend.html
   [51]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb5/igt@kms_fbcon_fbt@fbc-suspend.html
    - shard-kbl:          [INCOMPLETE][52] ([i915#155]) -> [PASS][53]
   [52]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-kbl4/igt@kms_fbcon_fbt@fbc-suspend.html
   [53]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl1/igt@kms_fbcon_fbt@fbc-suspend.html

  * igt@kms_flip@flip-vs-expired-vblank-interruptible@a-edp1:
    - shard-tglb:         [FAIL][54] ([i915#2598]) -> [PASS][55]
   [54]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb6/igt@kms_flip@flip-vs-expired-vblank-interruptible@a-edp1.html
   [55]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb5/igt@kms_flip@flip-vs-expired-vblank-interruptible@a-edp1.html

  * igt@kms_flip@flip-vs-panning@b-hdmi-a1:
    - shard-hsw:          [INCOMPLETE][56] -> [PASS][57]
   [56]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw6/igt@kms_flip@flip-vs-panning@b-hdmi-a1.html
   [57]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw6/igt@kms_flip@flip-vs-panning@b-hdmi-a1.html

  * igt@kms_psr@psr2_suspend:
    - shard-iclb:         [SKIP][58] ([fdo#109441]) -> [PASS][59] +1 similar issue
   [58]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb7/igt@kms_psr@psr2_suspend.html
   [59]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb2/igt@kms_psr@psr2_suspend.html

  * igt@kms_vblank@pipe-c-ts-continuation-modeset-rpm:
    - shard-hsw:          [SKIP][60] ([fdo#109271]) -> [PASS][61] +2 similar issues
   [60]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw7/igt@kms_vblank@pipe-c-ts-continuation-modeset-rpm.html
   [61]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw1/igt@kms_vblank@pipe-c-ts-continuation-modeset-rpm.html

  
#### Warnings ####

  * igt@i915_pm_dc@dc3co-vpb-simulation:
    - shard-iclb:         [SKIP][62] ([i915#658]) -> [SKIP][63] ([i915#588])
   [62]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb6/igt@i915_pm_dc@dc3co-vpb-simulation.html
   [63]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb2/igt@i915_pm_dc@dc3co-vpb-simulation.html

  * igt@i915_pm_rc6_residency@rc6-fence:
    - shard-iclb:         [WARN][64] ([i915#2681] / [i915#2684]) -> [WARN][65] ([i915#2684])
   [64]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-iclb1/igt@i915_pm_rc6_residency@rc6-fence.html
   [65]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-iclb5/igt@i915_pm_rc6_residency@rc6-fence.html

  * igt@kms_cursor_edge_walk@pipe-d-64x64-top-edge:
    - shard-hsw:          [INCOMPLETE][66] -> [SKIP][67] ([fdo#109271])
   [66]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-hsw6/igt@kms_cursor_edge_walk@pipe-d-64x64-top-edge.html
   [67]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-hsw2/igt@kms_cursor_edge_walk@pipe-d-64x64-top-edge.html

  * igt@runner@aborted:
    - shard-kbl:          [FAIL][68] ([i915#2295] / [i915#2722]) -> ([FAIL][69], [FAIL][70]) ([i915#2295] / [i915#2722] / [i915#483])
   [68]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-kbl7/igt@runner@aborted.html
   [69]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl2/igt@runner@aborted.html
   [70]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-kbl3/igt@runner@aborted.html
    - shard-glk:          ([FAIL][71], [FAIL][72]) ([i915#2295] / [i915#2722] / [i915#483] / [k.org#202321]) -> ([FAIL][73], [FAIL][74]) ([i915#2295] / [i915#2722] / [k.org#202321])
   [71]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk8/igt@runner@aborted.html
   [72]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-glk3/igt@runner@aborted.html
   [73]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk5/igt@runner@aborted.html
   [74]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-glk9/igt@runner@aborted.html
    - shard-tglb:         ([FAIL][75], [FAIL][76]) ([i915#1602] / [i915#2295] / [i915#2722]) -> ([FAIL][77], [FAIL][78]) ([i915#2295] / [i915#2722])
   [75]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb2/igt@runner@aborted.html
   [76]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9432/shard-tglb1/igt@runner@aborted.html
   [77]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb7/igt@runner@aborted.html
   [78]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/shard-tglb5/igt@runner@aborted.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
  [fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
  [i915#118]: https://gitlab.freedesktop.org/drm/intel/issues/118
  [i915#1185]: https://gitlab.freedesktop.org/drm/intel/issues/1185
  [i915#1436]: https://gitlab.freedesktop.org/drm/intel/issues/1436
  [i915#155]: https://gitlab.freedesktop.org/drm/intel/issues/155
  [i915#1602]: https://gitlab.freedesktop.org/drm/intel/issues/1602
  [i915#1798]: https://gitlab.freedesktop.org/drm/intel/issues/1798
  [i915#1887]: https://gitlab.freedesktop.org/drm/intel/issues/1887
  [i915#1982]: https://gitlab.freedesktop.org/drm/intel/issues/1982
  [i915#2055]: https://gitlab.freedesktop.org/drm/intel/issues/2055
  [i915#2122]: https://gitlab.freedesktop.org/drm/intel/issues/2122
  [i915#2295]: https://gitlab.freedesktop.org/drm/intel/issues/2295
  [i915#2389]: https://gitlab.freedesktop.org/drm/intel/issues/2389
  [i915#2411]: https://gitlab.freedesktop.org/drm/intel/issues/2411
  [i915#2483]: https://gitlab.freedesktop.org/drm/intel/issues/2483
  [i915#2598]: https://gitlab.freedesktop.org/drm/intel/issues/2598
  [i915#2635]: https://gitlab.freedesktop.org/drm/intel/issues/2635
  [i915#2637]: https://gitlab.freedesktop.org/drm/intel/issues/2637
  [i915#2681]: https://gitlab.freedesktop.org/drm/intel/issues/2681
  [i915#2684]: https://gitlab.freedesktop.org/drm/intel/issues/2684
  [i915#2722]: https://gitlab.freedesktop.org/drm/intel/issues/2722
  [i915#456]: https://gitlab.freedesktop.org/drm/intel/issues/456
  [i915#483]: https://gitlab.freedesktop.org/drm/intel/issues/483
  [i915#579]: https://gitlab.freedesktop.org/drm/intel/issues/579
  [i915#588]: https://gitlab.freedesktop.org/drm/intel/issues/588
  [i915#658]: https://gitlab.freedesktop.org/drm/intel/issues/658
  [i915#79]: https://gitlab.freedesktop.org/drm/intel/issues/79
  [i915#95]: https://gitlab.freedesktop.org/drm/intel/issues/95
  [k.org#202321]: https://bugzilla.kernel.org/show_bug.cgi?id=202321


Participating hosts (10 -> 8)
------------------------------

  Missing    (2): pig-skl-6260u pig-glk-j5005 


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_5878 -> IGTPW_5247
  * Piglit: piglit_4509 -> None

  CI-20190529: 20190529
  CI_DRM_9432: a7ed9b96ea3d9e89190a0cd08feb99e6b3e701a9 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_5247: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/index.html
  IGT_5878: e96c0d8e6952d892bcbbcdf004999880a4dfb42e @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
  piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5247/index.html

[-- Attachment #1.2: Type: text/html, Size: 20824 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* Re: [Intel-gfx] [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
  2020-12-03  9:59   ` [igt-dev] " Chris Wilson
@ 2020-12-04 10:52     ` Tvrtko Ursulin
  -1 siblings, 0 replies; 15+ messages in thread
From: Tvrtko Ursulin @ 2020-12-04 10:52 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev


On 03/12/2020 09:59, Chris Wilson wrote:
> Race the execution and interrupt handlers along a context, while
> closing it at a random time.
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>   tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
>   1 file changed, 60 insertions(+)
> 
> diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> index 194191def..18d5d1217 100644
> --- a/tests/i915/gem_ctx_exec.c
> +++ b/tests/i915/gem_ctx_exec.c
> @@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
>   	close(i915);
>   }
>   
> +static void close_race(int i915)
> +{
> +	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
> +	uint32_t *contexts;
> +
> +	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
> +	igt_assert(contexts != MAP_FAILED);
> +
> +	for (int child = 0; child < ncpus; child++)
> +		contexts[child] = gem_context_clone_with_engines(i915, 0);
> +
> +	igt_fork(child, ncpus) {
> +		igt_spin_t *spin;
> +
> +		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> +		igt_spin_end(spin);
> +		gem_sync(i915, spin->handle);
> +
> +		while (!READ_ONCE(contexts[ncpus])) {
> +			int64_t timeout = 1;
> +
> +			igt_spin_reset(spin);
> +			igt_assert(!igt_spin_has_started(spin));
> +
> +			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
> +			if (__gem_execbuf(i915, &spin->execbuf))
> +				continue;
> +
> +			igt_assert(gem_bo_busy(i915, spin->handle));

I've seen this line fail in CI results - any idea how that can happen?

> +			gem_wait(i915, spin->handle, &timeout); /* prime irq */

Is this depending on implementation specific behaviour, that we will 
leave the irq on after the waiter had exited?

> +			igt_spin_busywait_until_started(spin);
> +
> +			igt_spin_end(spin);
> +			gem_sync(i915, spin->handle);
> +		}
> +
> +		igt_spin_free(i915, spin);
> +	}
> +
> +	igt_until_timeout(5) {
> +		for (int child = 0; child < ncpus; child++) {
> +			gem_context_destroy(i915, contexts[child]);
> +			contexts[child] =
> +				gem_context_clone_with_engines(i915, 0);

Right so deliberate attempt to occasionally make the child use closed 
context. Presumably, well according to the CI results, it does manage to 
consistently hit it, which surprises me a bit. A comment here would be good.

> +		}
> +		usleep(1000);

Maybe add some randomness here? Or even a random busy loop within the 
child loop? I haven't looked at the i915 patch yet to know where the 
race actually is..

> +	}
> +
> +	contexts[ncpus] = 1;
> +	igt_waitchildren();
> +
> +	for (int child = 0; child < ncpus; child++)
> +		gem_context_destroy(i915, contexts[child]);
> +
> +	munmap(contexts, 4096);
> +}
> +
>   igt_main
>   {
>   	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
> @@ -380,6 +437,9 @@ igt_main
>   	igt_subtest("basic-nohangcheck")
>   		nohangcheck_hostile(fd);
>   
> +	igt_subtest("basic-close-race")
> +		close_race(fd);
> +
>   	igt_subtest("reset-pin-leak") {
>   		int i;
>   
> 

Regards,

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

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

* Re: [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-04 10:52     ` Tvrtko Ursulin
  0 siblings, 0 replies; 15+ messages in thread
From: Tvrtko Ursulin @ 2020-12-04 10:52 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev, Tvrtko Ursulin


On 03/12/2020 09:59, Chris Wilson wrote:
> Race the execution and interrupt handlers along a context, while
> closing it at a random time.
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>   tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
>   1 file changed, 60 insertions(+)
> 
> diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> index 194191def..18d5d1217 100644
> --- a/tests/i915/gem_ctx_exec.c
> +++ b/tests/i915/gem_ctx_exec.c
> @@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
>   	close(i915);
>   }
>   
> +static void close_race(int i915)
> +{
> +	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
> +	uint32_t *contexts;
> +
> +	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
> +	igt_assert(contexts != MAP_FAILED);
> +
> +	for (int child = 0; child < ncpus; child++)
> +		contexts[child] = gem_context_clone_with_engines(i915, 0);
> +
> +	igt_fork(child, ncpus) {
> +		igt_spin_t *spin;
> +
> +		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> +		igt_spin_end(spin);
> +		gem_sync(i915, spin->handle);
> +
> +		while (!READ_ONCE(contexts[ncpus])) {
> +			int64_t timeout = 1;
> +
> +			igt_spin_reset(spin);
> +			igt_assert(!igt_spin_has_started(spin));
> +
> +			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
> +			if (__gem_execbuf(i915, &spin->execbuf))
> +				continue;
> +
> +			igt_assert(gem_bo_busy(i915, spin->handle));

I've seen this line fail in CI results - any idea how that can happen?

> +			gem_wait(i915, spin->handle, &timeout); /* prime irq */

Is this depending on implementation specific behaviour, that we will 
leave the irq on after the waiter had exited?

> +			igt_spin_busywait_until_started(spin);
> +
> +			igt_spin_end(spin);
> +			gem_sync(i915, spin->handle);
> +		}
> +
> +		igt_spin_free(i915, spin);
> +	}
> +
> +	igt_until_timeout(5) {
> +		for (int child = 0; child < ncpus; child++) {
> +			gem_context_destroy(i915, contexts[child]);
> +			contexts[child] =
> +				gem_context_clone_with_engines(i915, 0);

Right so deliberate attempt to occasionally make the child use closed 
context. Presumably, well according to the CI results, it does manage to 
consistently hit it, which surprises me a bit. A comment here would be good.

> +		}
> +		usleep(1000);

Maybe add some randomness here? Or even a random busy loop within the 
child loop? I haven't looked at the i915 patch yet to know where the 
race actually is..

> +	}
> +
> +	contexts[ncpus] = 1;
> +	igt_waitchildren();
> +
> +	for (int child = 0; child < ncpus; child++)
> +		gem_context_destroy(i915, contexts[child]);
> +
> +	munmap(contexts, 4096);
> +}
> +
>   igt_main
>   {
>   	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
> @@ -380,6 +437,9 @@ igt_main
>   	igt_subtest("basic-nohangcheck")
>   		nohangcheck_hostile(fd);
>   
> +	igt_subtest("basic-close-race")
> +		close_race(fd);
> +
>   	igt_subtest("reset-pin-leak") {
>   		int i;
>   
> 

Regards,

Tvrtko
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* Re: [Intel-gfx] [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
  2020-12-04 10:52     ` Tvrtko Ursulin
@ 2020-12-04 11:13       ` Chris Wilson
  -1 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-04 11:13 UTC (permalink / raw)
  To: Tvrtko Ursulin, intel-gfx; +Cc: igt-dev

Quoting Tvrtko Ursulin (2020-12-04 10:52:23)
> 
> On 03/12/2020 09:59, Chris Wilson wrote:
> > Race the execution and interrupt handlers along a context, while
> > closing it at a random time.
> > 
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> > ---
> >   tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
> >   1 file changed, 60 insertions(+)
> > 
> > diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> > index 194191def..18d5d1217 100644
> > --- a/tests/i915/gem_ctx_exec.c
> > +++ b/tests/i915/gem_ctx_exec.c
> > @@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
> >       close(i915);
> >   }
> >   
> > +static void close_race(int i915)
> > +{
> > +     const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
> > +     uint32_t *contexts;
> > +
> > +     contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
> > +     igt_assert(contexts != MAP_FAILED);
> > +
> > +     for (int child = 0; child < ncpus; child++)
> > +             contexts[child] = gem_context_clone_with_engines(i915, 0);
> > +
> > +     igt_fork(child, ncpus) {
> > +             igt_spin_t *spin;
> > +
> > +             spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> > +             igt_spin_end(spin);
> > +             gem_sync(i915, spin->handle);
> > +
> > +             while (!READ_ONCE(contexts[ncpus])) {
> > +                     int64_t timeout = 1;
> > +
> > +                     igt_spin_reset(spin);
> > +                     igt_assert(!igt_spin_has_started(spin));
> > +
> > +                     spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
> > +                     if (__gem_execbuf(i915, &spin->execbuf))
> > +                             continue;
> > +
> > +                     igt_assert(gem_bo_busy(i915, spin->handle));
> 
> I've seen this line fail in CI results - any idea how that can happen?

Yes. The presumption we have in this test is that if gem_execbuf
succeeds, the request will execute.

However, see

  drm/i915/gem: Propagate error from cancelled submit due to context closure
  https://patchwork.freedesktop.org/patch/405392/?series=84531&rev=1

we are cancelling the request if we detect the context is closed before
the request is submitted, but still returned success (with an async
error).

I think the test makes a fair assumption, and it's easier than I was
thinking to return the error for the closed context, which makes the
gem_execbuf solid for this race.

> > +                     gem_wait(i915, spin->handle, &timeout); /* prime irq */
> 
> Is this depending on implementation specific behaviour, that we will 
> leave the irq on after the waiter had exited?

It's the best I can do. Nothing in the uAPI should ever govern exactly
the HW details.

And since this can be used to trick the machine into locking up under
irq pressure... Maybe not the best.

> > +                     igt_spin_busywait_until_started(spin);
> > +
> > +                     igt_spin_end(spin);
> > +                     gem_sync(i915, spin->handle);
> > +             }
> > +
> > +             igt_spin_free(i915, spin);
> > +     }
> > +
> > +     igt_until_timeout(5) {
> > +             for (int child = 0; child < ncpus; child++) {
> > +                     gem_context_destroy(i915, contexts[child]);
> > +                     contexts[child] =
> > +                             gem_context_clone_with_engines(i915, 0);
> 
> Right so deliberate attempt to occasionally make the child use closed 
> context. Presumably, well according to the CI results, it does manage to 
> consistently hit it, which surprises me a bit. A comment here would be good.
> 
> > +             }
> > +             usleep(1000);
> 
> Maybe add some randomness here? Or even a random busy loop within the 
> child loop? I haven't looked at the i915 patch yet to know where the 
> race actually is..

The CPU scheduler is great at providing randomness :)
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-04 11:13       ` Chris Wilson
  0 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-04 11:13 UTC (permalink / raw)
  To: Tvrtko Ursulin, intel-gfx; +Cc: igt-dev, Tvrtko Ursulin

Quoting Tvrtko Ursulin (2020-12-04 10:52:23)
> 
> On 03/12/2020 09:59, Chris Wilson wrote:
> > Race the execution and interrupt handlers along a context, while
> > closing it at a random time.
> > 
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> > ---
> >   tests/i915/gem_ctx_exec.c | 60 +++++++++++++++++++++++++++++++++++++++
> >   1 file changed, 60 insertions(+)
> > 
> > diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> > index 194191def..18d5d1217 100644
> > --- a/tests/i915/gem_ctx_exec.c
> > +++ b/tests/i915/gem_ctx_exec.c
> > @@ -336,6 +336,63 @@ static void nohangcheck_hostile(int i915)
> >       close(i915);
> >   }
> >   
> > +static void close_race(int i915)
> > +{
> > +     const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
> > +     uint32_t *contexts;
> > +
> > +     contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
> > +     igt_assert(contexts != MAP_FAILED);
> > +
> > +     for (int child = 0; child < ncpus; child++)
> > +             contexts[child] = gem_context_clone_with_engines(i915, 0);
> > +
> > +     igt_fork(child, ncpus) {
> > +             igt_spin_t *spin;
> > +
> > +             spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> > +             igt_spin_end(spin);
> > +             gem_sync(i915, spin->handle);
> > +
> > +             while (!READ_ONCE(contexts[ncpus])) {
> > +                     int64_t timeout = 1;
> > +
> > +                     igt_spin_reset(spin);
> > +                     igt_assert(!igt_spin_has_started(spin));
> > +
> > +                     spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
> > +                     if (__gem_execbuf(i915, &spin->execbuf))
> > +                             continue;
> > +
> > +                     igt_assert(gem_bo_busy(i915, spin->handle));
> 
> I've seen this line fail in CI results - any idea how that can happen?

Yes. The presumption we have in this test is that if gem_execbuf
succeeds, the request will execute.

However, see

  drm/i915/gem: Propagate error from cancelled submit due to context closure
  https://patchwork.freedesktop.org/patch/405392/?series=84531&rev=1

we are cancelling the request if we detect the context is closed before
the request is submitted, but still returned success (with an async
error).

I think the test makes a fair assumption, and it's easier than I was
thinking to return the error for the closed context, which makes the
gem_execbuf solid for this race.

> > +                     gem_wait(i915, spin->handle, &timeout); /* prime irq */
> 
> Is this depending on implementation specific behaviour, that we will 
> leave the irq on after the waiter had exited?

It's the best I can do. Nothing in the uAPI should ever govern exactly
the HW details.

And since this can be used to trick the machine into locking up under
irq pressure... Maybe not the best.

> > +                     igt_spin_busywait_until_started(spin);
> > +
> > +                     igt_spin_end(spin);
> > +                     gem_sync(i915, spin->handle);
> > +             }
> > +
> > +             igt_spin_free(i915, spin);
> > +     }
> > +
> > +     igt_until_timeout(5) {
> > +             for (int child = 0; child < ncpus; child++) {
> > +                     gem_context_destroy(i915, contexts[child]);
> > +                     contexts[child] =
> > +                             gem_context_clone_with_engines(i915, 0);
> 
> Right so deliberate attempt to occasionally make the child use closed 
> context. Presumably, well according to the CI results, it does manage to 
> consistently hit it, which surprises me a bit. A comment here would be good.
> 
> > +             }
> > +             usleep(1000);
> 
> Maybe add some randomness here? Or even a random busy loop within the 
> child loop? I haven't looked at the i915 patch yet to know where the 
> race actually is..

The CPU scheduler is great at providing randomness :)
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [Intel-gfx] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
  2020-12-03  9:59   ` [igt-dev] " Chris Wilson
@ 2020-12-04 11:27     ` Chris Wilson
  -1 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-04 11:27 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

v2: Some comments to handwave away the knowledge of internal
implementation details.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 84 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 84 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..5c6109237 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -43,6 +43,7 @@
 #include "i915/gem.h"
 #include "igt.h"
 #include "igt_dummyload.h"
+#include "igt_rand.h"
 #include "igt_sysfs.h"
 #include "sw_sync.h"
 
@@ -336,6 +337,86 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+		gem_sync(i915, spin->handle);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			/*
+			 * One race we are particularly interested in is the
+			 * handling of interrupt signaling along a closed
+			 * context. We want to see if we can catch the kernel
+			 * freeing the context while using it in the interrupt
+			 * handler.
+			 *
+			 * There's no API to mandate that the interrupt is
+			 * generate for a wait, nor that the implementation
+			 * details of the kernel will not change to remove
+			 * context access during interrupt processing. But
+			 * for now, this should be interesting.
+			 *
+			 * Even if the signaling implementation is changed,
+			 * racing context closure versus execbuf and looking
+			 * at the outcome is very useful.
+			 */
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		/*
+		 * Recreate all the contexts while they are in active use
+		 * by the children. This may race with any of their ioctls
+		 * and the kernel's context/request handling.
+		 */
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000 + hars_petruska_f54_1_random_unsafe() % 2000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +461,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

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

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

* [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
@ 2020-12-04 11:27     ` Chris Wilson
  0 siblings, 0 replies; 15+ messages in thread
From: Chris Wilson @ 2020-12-04 11:27 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, Tvrtko Ursulin, Chris Wilson

Race the execution and interrupt handlers along a context, while
closing it at a random time.

v2: Some comments to handwave away the knowledge of internal
implementation details.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 tests/i915/gem_ctx_exec.c | 84 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 84 insertions(+)

diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
index 194191def..5c6109237 100644
--- a/tests/i915/gem_ctx_exec.c
+++ b/tests/i915/gem_ctx_exec.c
@@ -43,6 +43,7 @@
 #include "i915/gem.h"
 #include "igt.h"
 #include "igt_dummyload.h"
+#include "igt_rand.h"
 #include "igt_sysfs.h"
 #include "sw_sync.h"
 
@@ -336,6 +337,86 @@ static void nohangcheck_hostile(int i915)
 	close(i915);
 }
 
+static void close_race(int i915)
+{
+	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
+	uint32_t *contexts;
+
+	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
+	igt_assert(contexts != MAP_FAILED);
+
+	for (int child = 0; child < ncpus; child++)
+		contexts[child] = gem_context_clone_with_engines(i915, 0);
+
+	igt_fork(child, ncpus) {
+		igt_spin_t *spin;
+
+		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
+		igt_spin_end(spin);
+		gem_sync(i915, spin->handle);
+
+		while (!READ_ONCE(contexts[ncpus])) {
+			int64_t timeout = 1;
+
+			igt_spin_reset(spin);
+			igt_assert(!igt_spin_has_started(spin));
+
+			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
+			if (__gem_execbuf(i915, &spin->execbuf))
+				continue;
+
+			/*
+			 * One race we are particularly interested in is the
+			 * handling of interrupt signaling along a closed
+			 * context. We want to see if we can catch the kernel
+			 * freeing the context while using it in the interrupt
+			 * handler.
+			 *
+			 * There's no API to mandate that the interrupt is
+			 * generate for a wait, nor that the implementation
+			 * details of the kernel will not change to remove
+			 * context access during interrupt processing. But
+			 * for now, this should be interesting.
+			 *
+			 * Even if the signaling implementation is changed,
+			 * racing context closure versus execbuf and looking
+			 * at the outcome is very useful.
+			 */
+
+			igt_assert(gem_bo_busy(i915, spin->handle));
+			gem_wait(i915, spin->handle, &timeout); /* prime irq */
+			igt_spin_busywait_until_started(spin);
+
+			igt_spin_end(spin);
+			gem_sync(i915, spin->handle);
+		}
+
+		igt_spin_free(i915, spin);
+	}
+
+	igt_until_timeout(5) {
+		/*
+		 * Recreate all the contexts while they are in active use
+		 * by the children. This may race with any of their ioctls
+		 * and the kernel's context/request handling.
+		 */
+		for (int child = 0; child < ncpus; child++) {
+			gem_context_destroy(i915, contexts[child]);
+			contexts[child] =
+				gem_context_clone_with_engines(i915, 0);
+		}
+		usleep(1000 + hars_petruska_f54_1_random_unsafe() % 2000);
+	}
+
+	contexts[ncpus] = 1;
+	igt_waitchildren();
+
+	for (int child = 0; child < ncpus; child++)
+		gem_context_destroy(i915, contexts[child]);
+
+	munmap(contexts, 4096);
+}
+
 igt_main
 {
 	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
@@ -380,6 +461,9 @@ igt_main
 	igt_subtest("basic-nohangcheck")
 		nohangcheck_hostile(fd);
 
+	igt_subtest("basic-close-race")
+		close_race(fd);
+
 	igt_subtest("reset-pin-leak") {
 		int i;
 
-- 
2.29.2

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✓ Fi.CI.BAT: success for i915/gem_ctx_exec: Exercise execution along context while closing it (rev3)
  2020-12-03  9:57 ` [igt-dev] " Chris Wilson
                   ` (3 preceding siblings ...)
  (?)
@ 2020-12-04 12:08 ` Patchwork
  -1 siblings, 0 replies; 15+ messages in thread
From: Patchwork @ 2020-12-04 12:08 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev


[-- Attachment #1.1: Type: text/plain, Size: 2043 bytes --]

== Series Details ==

Series: i915/gem_ctx_exec: Exercise execution along context while closing it (rev3)
URL   : https://patchwork.freedesktop.org/series/84530/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_9441 -> IGTPW_5248
====================================================

Summary
-------

  **SUCCESS**

  No regressions found.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html

Known issues
------------

  Here are the changes found in IGTPW_5248 that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@prime_vgem@basic-fence-flip:
    - fi-tgl-y:           [PASS][1] -> [DMESG-WARN][2] ([i915#402]) +1 similar issue
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/fi-tgl-y/igt@prime_vgem@basic-fence-flip.html
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/fi-tgl-y/igt@prime_vgem@basic-fence-flip.html

  
#### Possible fixes ####

  * igt@gem_exec_gttfill@basic:
    - fi-tgl-y:           [DMESG-WARN][3] ([i915#402]) -> [PASS][4] +2 similar issues
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/fi-tgl-y/igt@gem_exec_gttfill@basic.html
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/fi-tgl-y/igt@gem_exec_gttfill@basic.html

  
  [i915#402]: https://gitlab.freedesktop.org/drm/intel/issues/402


Participating hosts (43 -> 38)
------------------------------

  Missing    (5): fi-ilk-m540 fi-hsw-4200u fi-bsw-cyan fi-dg1-1 fi-bdw-samus 


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_5880 -> IGTPW_5248

  CI-20190529: 20190529
  CI_DRM_9441: 6e992bb7585d1bee238776d8fe0512a70a22a1a0 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_5248: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html
  IGT_5880: d67bad61dc9a7515f94a7eecadd3bcd6b4f9d49e @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools



== Testlist changes ==

+igt@gem_ctx_exec@basic-close-race

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html

[-- Attachment #1.2: Type: text/html, Size: 2731 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✓ Fi.CI.IGT: success for i915/gem_ctx_exec: Exercise execution along context while closing it (rev3)
  2020-12-03  9:57 ` [igt-dev] " Chris Wilson
                   ` (4 preceding siblings ...)
  (?)
@ 2020-12-04 13:30 ` Patchwork
  -1 siblings, 0 replies; 15+ messages in thread
From: Patchwork @ 2020-12-04 13:30 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev


[-- Attachment #1.1: Type: text/plain, Size: 17591 bytes --]

== Series Details ==

Series: i915/gem_ctx_exec: Exercise execution along context while closing it (rev3)
URL   : https://patchwork.freedesktop.org/series/84530/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_9441_full -> IGTPW_5248_full
====================================================

Summary
-------

  **SUCCESS**

  No regressions found.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html

Possible new issues
-------------------

  Here are the unknown changes that may have been introduced in IGTPW_5248_full:

### IGT changes ###

#### Possible regressions ####

  * {igt@gem_ctx_exec@basic-close-race} (NEW):
    - shard-tglb:         NOTRUN -> [TIMEOUT][1]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb1/igt@gem_ctx_exec@basic-close-race.html
    - shard-glk:          NOTRUN -> [TIMEOUT][2]
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk7/igt@gem_ctx_exec@basic-close-race.html
    - shard-apl:          NOTRUN -> [FAIL][3]
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl4/igt@gem_ctx_exec@basic-close-race.html
    - shard-kbl:          NOTRUN -> [TIMEOUT][4]
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl7/igt@gem_ctx_exec@basic-close-race.html
    - shard-iclb:         NOTRUN -> [TIMEOUT][5]
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb1/igt@gem_ctx_exec@basic-close-race.html
    - shard-hsw:          NOTRUN -> [TIMEOUT][6]
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-hsw1/igt@gem_ctx_exec@basic-close-race.html
    - shard-snb:          NOTRUN -> [FAIL][7]
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-snb4/igt@gem_ctx_exec@basic-close-race.html

  
New tests
---------

  New tests have been introduced between CI_DRM_9441_full and IGTPW_5248_full:

### New IGT tests (1) ###

  * igt@gem_ctx_exec@basic-close-race:
    - Statuses : 2 fail(s) 5 timeout(s)
    - Exec time: [5.43, 121.42] s

  

Known issues
------------

  Here are the changes found in IGTPW_5248_full that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@gem_exec_suspend@basic-s3:
    - shard-kbl:          [PASS][8] -> [INCOMPLETE][9] ([i915#155] / [i915#180] / [i915#2369])
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl3/igt@gem_exec_suspend@basic-s3.html
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl2/igt@gem_exec_suspend@basic-s3.html

  * igt@i915_pm_rpm@fences:
    - shard-kbl:          [PASS][10] -> [SKIP][11] ([fdo#109271])
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl6/igt@i915_pm_rpm@fences.html
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl3/igt@i915_pm_rpm@fences.html
    - shard-iclb:         [PASS][12] -> [SKIP][13] ([i915#579])
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb7/igt@i915_pm_rpm@fences.html
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb5/igt@i915_pm_rpm@fences.html
    - shard-hsw:          [PASS][14] -> [SKIP][15] ([fdo#109271])
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-hsw7/igt@i915_pm_rpm@fences.html
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-hsw1/igt@i915_pm_rpm@fences.html
    - shard-glk:          [PASS][16] -> [SKIP][17] ([fdo#109271])
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk8/igt@i915_pm_rpm@fences.html
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk2/igt@i915_pm_rpm@fences.html
    - shard-apl:          [PASS][18] -> [SKIP][19] ([fdo#109271])
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-apl4/igt@i915_pm_rpm@fences.html
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl7/igt@i915_pm_rpm@fences.html

  * igt@i915_suspend@fence-restore-untiled:
    - shard-iclb:         [PASS][20] -> [INCOMPLETE][21] ([i915#1185])
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb7/igt@i915_suspend@fence-restore-untiled.html
   [21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb5/igt@i915_suspend@fence-restore-untiled.html
    - shard-glk:          [PASS][22] -> [INCOMPLETE][23] ([i915#2635])
   [22]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk5/igt@i915_suspend@fence-restore-untiled.html
   [23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk2/igt@i915_suspend@fence-restore-untiled.html
    - shard-apl:          [PASS][24] -> [INCOMPLETE][25] ([i915#2635])
   [24]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-apl4/igt@i915_suspend@fence-restore-untiled.html
   [25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl7/igt@i915_suspend@fence-restore-untiled.html
    - shard-kbl:          [PASS][26] -> [INCOMPLETE][27] ([i915#155])
   [26]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl2/igt@i915_suspend@fence-restore-untiled.html
   [27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl3/igt@i915_suspend@fence-restore-untiled.html
    - shard-hsw:          [PASS][28] -> [INCOMPLETE][29] ([i915#2637])
   [28]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-hsw2/igt@i915_suspend@fence-restore-untiled.html
   [29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-hsw1/igt@i915_suspend@fence-restore-untiled.html

  * igt@kms_async_flips@test-time-stamp:
    - shard-tglb:         [PASS][30] -> [FAIL][31] ([i915#2574])
   [30]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb1/igt@kms_async_flips@test-time-stamp.html
   [31]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb5/igt@kms_async_flips@test-time-stamp.html

  * igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff:
    - shard-apl:          [PASS][32] -> [FAIL][33] ([i915#49])
   [32]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-apl4/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html
   [33]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl2/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html
    - shard-kbl:          [PASS][34] -> [FAIL][35] ([i915#49])
   [34]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl7/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html
   [35]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl6/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html
    - shard-glk:          [PASS][36] -> [FAIL][37] ([i915#49])
   [36]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk7/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html
   [37]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk3/igt@kms_frontbuffer_tracking@fbc-1p-primscrn-cur-indfb-onoff.html

  * igt@kms_plane@plane-panning-bottom-right-suspend-pipe-d-planes:
    - shard-tglb:         [PASS][38] -> [INCOMPLETE][39] ([i915#1436] / [i915#1982] / [i915#456])
   [38]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb7/igt@kms_plane@plane-panning-bottom-right-suspend-pipe-d-planes.html
   [39]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb5/igt@kms_plane@plane-panning-bottom-right-suspend-pipe-d-planes.html

  * igt@kms_psr@psr2_cursor_plane_move:
    - shard-iclb:         [PASS][40] -> [SKIP][41] ([fdo#109441]) +2 similar issues
   [40]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb2/igt@kms_psr@psr2_cursor_plane_move.html
   [41]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb5/igt@kms_psr@psr2_cursor_plane_move.html

  
#### Possible fixes ####

  * igt@gem_exec_gttfill@engines@rcs0:
    - shard-glk:          [DMESG-WARN][42] ([i915#118] / [i915#95]) -> [PASS][43] +2 similar issues
   [42]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk7/igt@gem_exec_gttfill@engines@rcs0.html
   [43]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk6/igt@gem_exec_gttfill@engines@rcs0.html

  * igt@i915_pm_rpm@sysfs-read:
    - shard-iclb:         [SKIP][44] ([i915#579]) -> [PASS][45]
   [44]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb3/igt@i915_pm_rpm@sysfs-read.html
   [45]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb3/igt@i915_pm_rpm@sysfs-read.html
    - shard-tglb:         [SKIP][46] ([i915#579]) -> [PASS][47]
   [46]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb2/igt@i915_pm_rpm@sysfs-read.html
   [47]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb7/igt@i915_pm_rpm@sysfs-read.html

  * igt@kms_color@pipe-a-ctm-max:
    - shard-kbl:          [FAIL][48] ([i915#1292]) -> [PASS][49]
   [48]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl3/igt@kms_color@pipe-a-ctm-max.html
   [49]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl1/igt@kms_color@pipe-a-ctm-max.html
    - shard-apl:          [FAIL][50] ([i915#1292]) -> [PASS][51]
   [50]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-apl6/igt@kms_color@pipe-a-ctm-max.html
   [51]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl8/igt@kms_color@pipe-a-ctm-max.html

  * igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy:
    - shard-glk:          [FAIL][52] ([i915#72]) -> [PASS][53]
   [52]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk1/igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy.html
   [53]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk9/igt@kms_cursor_legacy@2x-long-flip-vs-cursor-legacy.html

  * igt@kms_psr2_su@frontbuffer:
    - shard-iclb:         [SKIP][54] ([fdo#109642] / [fdo#111068]) -> [PASS][55]
   [54]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb1/igt@kms_psr2_su@frontbuffer.html
   [55]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb2/igt@kms_psr2_su@frontbuffer.html

  * igt@kms_psr@psr2_sprite_mmap_gtt:
    - shard-iclb:         [SKIP][56] ([fdo#109441]) -> [PASS][57] +1 similar issue
   [56]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb3/igt@kms_psr@psr2_sprite_mmap_gtt.html
   [57]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb2/igt@kms_psr@psr2_sprite_mmap_gtt.html

  * igt@perf_pmu@rc6-runtime-pm:
    - shard-glk:          [SKIP][58] ([fdo#109271]) -> [PASS][59] +1 similar issue
   [58]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-glk1/igt@perf_pmu@rc6-runtime-pm.html
   [59]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-glk7/igt@perf_pmu@rc6-runtime-pm.html
    - shard-apl:          [SKIP][60] ([fdo#109271]) -> [PASS][61] +1 similar issue
   [60]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-apl2/igt@perf_pmu@rc6-runtime-pm.html
   [61]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-apl4/igt@perf_pmu@rc6-runtime-pm.html
    - shard-kbl:          [SKIP][62] ([fdo#109271]) -> [PASS][63] +1 similar issue
   [62]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl6/igt@perf_pmu@rc6-runtime-pm.html
   [63]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl7/igt@perf_pmu@rc6-runtime-pm.html
    - shard-tglb:         [SKIP][64] ([fdo#111719]) -> [PASS][65]
   [64]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb6/igt@perf_pmu@rc6-runtime-pm.html
   [65]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb1/igt@perf_pmu@rc6-runtime-pm.html
    - shard-hsw:          [SKIP][66] ([fdo#109271]) -> [PASS][67] +1 similar issue
   [66]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-hsw6/igt@perf_pmu@rc6-runtime-pm.html
   [67]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-hsw1/igt@perf_pmu@rc6-runtime-pm.html
    - shard-iclb:         [SKIP][68] ([i915#293]) -> [PASS][69]
   [68]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb1/igt@perf_pmu@rc6-runtime-pm.html
   [69]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb1/igt@perf_pmu@rc6-runtime-pm.html

  
#### Warnings ####

  * igt@i915_pm_rc6_residency@rc6-fence:
    - shard-iclb:         [WARN][70] ([i915#1804] / [i915#2684]) -> [WARN][71] ([i915#2684])
   [70]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb7/igt@i915_pm_rc6_residency@rc6-fence.html
   [71]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb2/igt@i915_pm_rc6_residency@rc6-fence.html

  * igt@i915_pm_rc6_residency@rc6-idle:
    - shard-iclb:         [WARN][72] ([i915#2684]) -> [WARN][73] ([i915#1804] / [i915#2684])
   [72]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb2/igt@i915_pm_rc6_residency@rc6-idle.html
   [73]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb6/igt@i915_pm_rc6_residency@rc6-idle.html

  * igt@i915_pm_rpm@modeset-pc8-residency-stress:
    - shard-tglb:         [SKIP][74] ([i915#579]) -> [SKIP][75] ([fdo#109506] / [i915#2411])
   [74]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb6/igt@i915_pm_rpm@modeset-pc8-residency-stress.html
   [75]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb8/igt@i915_pm_rpm@modeset-pc8-residency-stress.html
    - shard-iclb:         [SKIP][76] ([i915#579]) -> [SKIP][77] ([fdo#109293] / [fdo#109506])
   [76]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-iclb1/igt@i915_pm_rpm@modeset-pc8-residency-stress.html
   [77]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-iclb8/igt@i915_pm_rpm@modeset-pc8-residency-stress.html

  * igt@runner@aborted:
    - shard-kbl:          ([FAIL][78], [FAIL][79]) ([i915#2295] / [i915#2722] / [i915#483] / [i915#92]) -> ([FAIL][80], [FAIL][81]) ([i915#2295] / [i915#2722] / [i915#483])
   [78]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl6/igt@runner@aborted.html
   [79]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-kbl2/igt@runner@aborted.html
   [80]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl7/igt@runner@aborted.html
   [81]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-kbl2/igt@runner@aborted.html
    - shard-tglb:         [FAIL][82] ([i915#2295] / [i915#2722]) -> ([FAIL][83], [FAIL][84]) ([i915#1814] / [i915#2295] / [i915#2722])
   [82]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_9441/shard-tglb7/igt@runner@aborted.html
   [83]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb5/igt@runner@aborted.html
   [84]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/shard-tglb5/igt@runner@aborted.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
  [fdo#109293]: https://bugs.freedesktop.org/show_bug.cgi?id=109293
  [fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
  [fdo#109506]: https://bugs.freedesktop.org/show_bug.cgi?id=109506
  [fdo#109642]: https://bugs.freedesktop.org/show_bug.cgi?id=109642
  [fdo#111068]: https://bugs.freedesktop.org/show_bug.cgi?id=111068
  [fdo#111719]: https://bugs.freedesktop.org/show_bug.cgi?id=111719
  [i915#118]: https://gitlab.freedesktop.org/drm/intel/issues/118
  [i915#1185]: https://gitlab.freedesktop.org/drm/intel/issues/1185
  [i915#1292]: https://gitlab.freedesktop.org/drm/intel/issues/1292
  [i915#1436]: https://gitlab.freedesktop.org/drm/intel/issues/1436
  [i915#155]: https://gitlab.freedesktop.org/drm/intel/issues/155
  [i915#180]: https://gitlab.freedesktop.org/drm/intel/issues/180
  [i915#1804]: https://gitlab.freedesktop.org/drm/intel/issues/1804
  [i915#1814]: https://gitlab.freedesktop.org/drm/intel/issues/1814
  [i915#1982]: https://gitlab.freedesktop.org/drm/intel/issues/1982
  [i915#2295]: https://gitlab.freedesktop.org/drm/intel/issues/2295
  [i915#2369]: https://gitlab.freedesktop.org/drm/intel/issues/2369
  [i915#2411]: https://gitlab.freedesktop.org/drm/intel/issues/2411
  [i915#2574]: https://gitlab.freedesktop.org/drm/intel/issues/2574
  [i915#2635]: https://gitlab.freedesktop.org/drm/intel/issues/2635
  [i915#2637]: https://gitlab.freedesktop.org/drm/intel/issues/2637
  [i915#2684]: https://gitlab.freedesktop.org/drm/intel/issues/2684
  [i915#2722]: https://gitlab.freedesktop.org/drm/intel/issues/2722
  [i915#293]: https://gitlab.freedesktop.org/drm/intel/issues/293
  [i915#456]: https://gitlab.freedesktop.org/drm/intel/issues/456
  [i915#483]: https://gitlab.freedesktop.org/drm/intel/issues/483
  [i915#49]: https://gitlab.freedesktop.org/drm/intel/issues/49
  [i915#579]: https://gitlab.freedesktop.org/drm/intel/issues/579
  [i915#72]: https://gitlab.freedesktop.org/drm/intel/issues/72
  [i915#92]: https://gitlab.freedesktop.org/drm/intel/issues/92
  [i915#95]: https://gitlab.freedesktop.org/drm/intel/issues/95


Participating hosts (10 -> 8)
------------------------------

  Missing    (2): pig-skl-6260u pig-glk-j5005 


Build changes
-------------

  * CI: CI-20190529 -> None
  * IGT: IGT_5880 -> IGTPW_5248
  * Piglit: piglit_4509 -> None

  CI-20190529: 20190529
  CI_DRM_9441: 6e992bb7585d1bee238776d8fe0512a70a22a1a0 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_5248: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html
  IGT_5880: d67bad61dc9a7515f94a7eecadd3bcd6b4f9d49e @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
  piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5248/index.html

[-- Attachment #1.2: Type: text/html, Size: 21239 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* Re: [Intel-gfx] [igt-dev] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it
  2020-12-04 11:27     ` [igt-dev] " Chris Wilson
  (?)
@ 2020-12-04 13:53     ` Tvrtko Ursulin
  -1 siblings, 0 replies; 15+ messages in thread
From: Tvrtko Ursulin @ 2020-12-04 13:53 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev


On 04/12/2020 11:27, Chris Wilson wrote:
> Race the execution and interrupt handlers along a context, while
> closing it at a random time.
> 
> v2: Some comments to handwave away the knowledge of internal
> implementation details.
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>   tests/i915/gem_ctx_exec.c | 84 +++++++++++++++++++++++++++++++++++++++
>   1 file changed, 84 insertions(+)
> 
> diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> index 194191def..5c6109237 100644
> --- a/tests/i915/gem_ctx_exec.c
> +++ b/tests/i915/gem_ctx_exec.c
> @@ -43,6 +43,7 @@
>   #include "i915/gem.h"
>   #include "igt.h"
>   #include "igt_dummyload.h"
> +#include "igt_rand.h"
>   #include "igt_sysfs.h"
>   #include "sw_sync.h"
>   
> @@ -336,6 +337,86 @@ static void nohangcheck_hostile(int i915)
>   	close(i915);
>   }
>   
> +static void close_race(int i915)
> +{
> +	const int ncpus = sysconf(_SC_NPROCESSORS_ONLN);
> +	uint32_t *contexts;
> +
> +	contexts = mmap(NULL, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
> +	igt_assert(contexts != MAP_FAILED);
> +
> +	for (int child = 0; child < ncpus; child++)
> +		contexts[child] = gem_context_clone_with_engines(i915, 0);
> +
> +	igt_fork(child, ncpus) {
> +		igt_spin_t *spin;
> +
> +		spin = igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> +		igt_spin_end(spin);
> +		gem_sync(i915, spin->handle);
> +
> +		while (!READ_ONCE(contexts[ncpus])) {
> +			int64_t timeout = 1;
> +
> +			igt_spin_reset(spin);
> +			igt_assert(!igt_spin_has_started(spin));
> +
> +			spin->execbuf.rsvd1 = READ_ONCE(contexts[child]);
> +			if (__gem_execbuf(i915, &spin->execbuf))
> +				continue;
> +
> +			/*
> +			 * One race we are particularly interested in is the
> +			 * handling of interrupt signaling along a closed
> +			 * context. We want to see if we can catch the kernel
> +			 * freeing the context while using it in the interrupt
> +			 * handler.
> +			 *
> +			 * There's no API to mandate that the interrupt is
> +			 * generate for a wait, nor that the implementation
> +			 * details of the kernel will not change to remove
> +			 * context access during interrupt processing. But
> +			 * for now, this should be interesting.
> +			 *
> +			 * Even if the signaling implementation is changed,
> +			 * racing context closure versus execbuf and looking
> +			 * at the outcome is very useful.
> +			 */
> +
> +			igt_assert(gem_bo_busy(i915, spin->handle));
> +			gem_wait(i915, spin->handle, &timeout); /* prime irq */
> +			igt_spin_busywait_until_started(spin);
> +
> +			igt_spin_end(spin);
> +			gem_sync(i915, spin->handle);
> +		}
> +
> +		igt_spin_free(i915, spin);
> +	}
> +
> +	igt_until_timeout(5) {
> +		/*
> +		 * Recreate all the contexts while they are in active use
> +		 * by the children. This may race with any of their ioctls
> +		 * and the kernel's context/request handling.
> +		 */
> +		for (int child = 0; child < ncpus; child++) {
> +			gem_context_destroy(i915, contexts[child]);
> +			contexts[child] =
> +				gem_context_clone_with_engines(i915, 0);
> +		}
> +		usleep(1000 + hars_petruska_f54_1_random_unsafe() % 2000);
> +	}
> +
> +	contexts[ncpus] = 1;
> +	igt_waitchildren();
> +
> +	for (int child = 0; child < ncpus; child++)
> +		gem_context_destroy(i915, contexts[child]);
> +
> +	munmap(contexts, 4096);
> +}
> +
>   igt_main
>   {
>   	const uint32_t batch[2] = { 0, MI_BATCH_BUFFER_END };
> @@ -380,6 +461,9 @@ igt_main
>   	igt_subtest("basic-nohangcheck")
>   		nohangcheck_hostile(fd);
>   
> +	igt_subtest("basic-close-race")
> +		close_race(fd);
> +
>   	igt_subtest("reset-pin-leak") {
>   		int i;
>   
> 

Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Regards,

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

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

end of thread, other threads:[~2020-12-04 13:53 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-03  9:57 [Intel-gfx] [PATCH i-g-t] i915/gem_ctx_exec: Exercise execution along context while closing it Chris Wilson
2020-12-03  9:57 ` [igt-dev] " Chris Wilson
2020-12-03  9:59 ` [Intel-gfx] " Chris Wilson
2020-12-03  9:59   ` [igt-dev] " Chris Wilson
2020-12-04 10:52   ` [Intel-gfx] " Tvrtko Ursulin
2020-12-04 10:52     ` Tvrtko Ursulin
2020-12-04 11:13     ` [Intel-gfx] " Chris Wilson
2020-12-04 11:13       ` Chris Wilson
2020-12-04 11:27   ` [Intel-gfx] " Chris Wilson
2020-12-04 11:27     ` [igt-dev] " Chris Wilson
2020-12-04 13:53     ` [Intel-gfx] " Tvrtko Ursulin
2020-12-03 11:21 ` [igt-dev] ✓ Fi.CI.BAT: success for i915/gem_ctx_exec: Exercise execution along context while closing it (rev2) Patchwork
2020-12-03 16:10 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
2020-12-04 12:08 ` [igt-dev] ✓ Fi.CI.BAT: success for i915/gem_ctx_exec: Exercise execution along context while closing it (rev3) Patchwork
2020-12-04 13:30 ` [igt-dev] ✓ 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.