summaryrefslogtreecommitdiff
path: root/tests/i915/i915_hangman.c
diff options
context:
space:
mode:
authorJohn Harrison <John.C.Harrison@Intel.com>2022-01-14 10:17:08 -0800
committerAshutosh Dixit <ashutosh.dixit@intel.com>2022-01-18 12:43:38 -0800
commit8d45b02048f9e1b5a4bf05c95dbc71628a95b316 (patch)
tree4a40ab38af086805a7e2291600c850b8d66cd931 /tests/i915/i915_hangman.c
parent9a0cb77d7610d8c2d33e25e773f6f4a4c4d972bc (diff)
tests/i915/i915_hangman: Run background task on all engines
As opposed to only on the non-target engines. This means that there is some other workload present for the scheduler to switch between and so detet the hang immediately. Signed-off-by: John Harrison <John.C.Harrison@Intel.com> Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Diffstat (limited to 'tests/i915/i915_hangman.c')
-rw-r--r--tests/i915/i915_hangman.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/i915/i915_hangman.c b/tests/i915/i915_hangman.c
index 24087931..a1aeeba6 100644
--- a/tests/i915/i915_hangman.c
+++ b/tests/i915/i915_hangman.c
@@ -298,12 +298,14 @@ test_engine_hang(const intel_ctx_t *ctx,
igt_skip_on(flags & IGT_SPIN_INVALID_CS &&
gem_engine_has_cmdparser(device, &ctx->cfg, e->flags));
- /* Fill all the other engines with background load */
+ /*
+ * Fill all engines with background load.
+ * This verifies that independent engines are unaffected and gives
+ * the target engine something to switch between so it notices the
+ * hang.
+ */
num_ctx = 0;
for_each_ctx_engine(device, ctx, other) {
- if (other->flags == e->flags)
- continue;
-
local_ctx[num_ctx] = intel_ctx_create(device, &ctx->cfg);
ahndN = get_reloc_ahnd(device, local_ctx[num_ctx]->id);
spin = __igt_spin_new(device,