* [PATCH] drm/i915/selftests: Check for hangs mid context execution tests @ 2018-10-10 12:51 Chris Wilson 2018-10-10 13:51 ` ✓ Fi.CI.BAT: success for " Patchwork ` (3 more replies) 0 siblings, 4 replies; 7+ messages in thread From: Chris Wilson @ 2018-10-10 12:51 UTC (permalink / raw) To: intel-gfx Use the live_test struct to record the reset count before and compare it at the end of the test to assert that no mystery hang occurred during the test. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> --- .../gpu/drm/i915/selftests/i915_gem_context.c | 22 ++++++++++++++----- 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/i915/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/selftests/i915_gem_context.c index 913c0f83f86a..ea165a644d79 100644 --- a/drivers/gpu/drm/i915/selftests/i915_gem_context.c +++ b/drivers/gpu/drm/i915/selftests/i915_gem_context.c @@ -531,10 +531,11 @@ static int igt_ctx_exec(void *arg) { struct drm_i915_private *i915 = arg; struct drm_i915_gem_object *obj = NULL; + unsigned long ncontexts, ndwords, dw; struct drm_file *file; IGT_TIMEOUT(end_time); LIST_HEAD(objects); - unsigned long ncontexts, ndwords, dw; + struct live_test t; int err = -ENODEV; /* @@ -552,6 +553,10 @@ static int igt_ctx_exec(void *arg) mutex_lock(&i915->drm.struct_mutex); + err = begin_live_test(&t, i915, __func__, ""); + if (err) + goto out_unlock; + ncontexts = 0; ndwords = 0; dw = 0; @@ -616,7 +621,7 @@ static int igt_ctx_exec(void *arg) } out_unlock: - if (igt_flush_test(i915, I915_WAIT_LOCKED)) + if (end_live_test(&t)) err = -EIO; mutex_unlock(&i915->drm.struct_mutex); @@ -628,13 +633,14 @@ static int igt_ctx_readonly(void *arg) { struct drm_i915_private *i915 = arg; struct drm_i915_gem_object *obj = NULL; + struct i915_gem_context *ctx; + struct i915_hw_ppgtt *ppgtt; + unsigned long ndwords, dw; struct drm_file *file; I915_RND_STATE(prng); IGT_TIMEOUT(end_time); LIST_HEAD(objects); - struct i915_gem_context *ctx; - struct i915_hw_ppgtt *ppgtt; - unsigned long ndwords, dw; + struct live_test t; int err = -ENODEV; /* @@ -649,6 +655,10 @@ static int igt_ctx_readonly(void *arg) mutex_lock(&i915->drm.struct_mutex); + err = begin_live_test(&t, i915, __func__, ""); + if (err) + goto out_unlock; + ctx = i915_gem_create_context(i915, file->driver_priv); if (IS_ERR(ctx)) { err = PTR_ERR(ctx); @@ -721,7 +731,7 @@ static int igt_ctx_readonly(void *arg) } out_unlock: - if (igt_flush_test(i915, I915_WAIT_LOCKED)) + if (end_live_test(&t)) err = -EIO; mutex_unlock(&i915->drm.struct_mutex); -- 2.19.1 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply related [flat|nested] 7+ messages in thread
* ✓ Fi.CI.BAT: success for drm/i915/selftests: Check for hangs mid context execution tests 2018-10-10 12:51 [PATCH] drm/i915/selftests: Check for hangs mid context execution tests Chris Wilson @ 2018-10-10 13:51 ` Patchwork 2018-10-10 18:37 ` ✓ Fi.CI.IGT: " Patchwork ` (2 subsequent siblings) 3 siblings, 0 replies; 7+ messages in thread From: Patchwork @ 2018-10-10 13:51 UTC (permalink / raw) To: Chris Wilson; +Cc: intel-gfx == Series Details == Series: drm/i915/selftests: Check for hangs mid context execution tests URL : https://patchwork.freedesktop.org/series/50801/ State : success == Summary == = CI Bug Log - changes from CI_DRM_4961 -> Patchwork_10413 = == Summary - SUCCESS == No regressions found. External URL: https://patchwork.freedesktop.org/api/1.0/series/50801/revisions/1/mbox/ == Known issues == Here are the changes found in Patchwork_10413 that come from known issues: === IGT changes === ==== Issues hit ==== igt@kms_pipe_crc_basic@read-crc-pipe-b-frame-sequence: fi-ilk-650: PASS -> DMESG-WARN (fdo#106387) +1 ==== Possible fixes ==== igt@gem_exec_suspend@basic-s3: fi-cfl-8109u: DMESG-WARN (fdo#107345) -> PASS +1 igt@kms_chamelium@dp-crc-fast: fi-kbl-7500u: FAIL (fdo#103841) -> PASS +2 igt@kms_chamelium@dp-hpd-fast: fi-skl-6700k2: FAIL (fdo#103841) -> SKIP +4 igt@kms_chamelium@hdmi-crc-fast: fi-skl-6700k2: FAIL (fdo#103841) -> PASS +3 igt@kms_chamelium@vga-hpd-fast: fi-kbl-7500u: FAIL (fdo#103841) -> SKIP +4 igt@kms_pipe_crc_basic@hang-read-crc-pipe-a: fi-byt-clapper: FAIL (fdo#103191, fdo#107362) -> PASS ==== Warnings ==== igt@kms_chamelium@common-hpd-after-suspend: fi-kbl-7500u: FAIL (fdo#103841) -> DMESG-WARN (fdo#102505, fdo#105079, fdo#105602) fdo#102505 https://bugs.freedesktop.org/show_bug.cgi?id=102505 fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191 fdo#103841 https://bugs.freedesktop.org/show_bug.cgi?id=103841 fdo#105079 https://bugs.freedesktop.org/show_bug.cgi?id=105079 fdo#105602 https://bugs.freedesktop.org/show_bug.cgi?id=105602 fdo#106387 https://bugs.freedesktop.org/show_bug.cgi?id=106387 fdo#107345 https://bugs.freedesktop.org/show_bug.cgi?id=107345 fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362 == Participating hosts (48 -> 41) == Missing (7): fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-icl-u2 fi-bsw-cyan fi-ctg-p8600 fi-pnv-d510 == Build changes == * Linux: CI_DRM_4961 -> Patchwork_10413 CI_DRM_4961: 1b9d983587107509e70d14509fcd304b19ae0ce0 @ git://anongit.freedesktop.org/gfx-ci/linux IGT_4673: 54cb1aeb4e50dea9f3abae632e317875d147c4ab @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools Patchwork_10413: 2f79f218c3ba344e17eb939a94f45b144070967d @ git://anongit.freedesktop.org/gfx-ci/linux == Linux commits == 2f79f218c3ba drm/i915/selftests: Check for hangs mid context execution tests == Logs == For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_10413/issues.html _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* ✓ Fi.CI.IGT: success for drm/i915/selftests: Check for hangs mid context execution tests 2018-10-10 12:51 [PATCH] drm/i915/selftests: Check for hangs mid context execution tests Chris Wilson 2018-10-10 13:51 ` ✓ Fi.CI.BAT: success for " Patchwork @ 2018-10-10 18:37 ` Patchwork 2018-10-12 12:24 ` [PATCH v2] " Chris Wilson 2018-10-12 13:09 ` ✗ Fi.CI.BAT: failure for drm/i915/selftests: Check for hangs mid context execution tests (rev2) Patchwork 3 siblings, 0 replies; 7+ messages in thread From: Patchwork @ 2018-10-10 18:37 UTC (permalink / raw) To: Chris Wilson; +Cc: intel-gfx == Series Details == Series: drm/i915/selftests: Check for hangs mid context execution tests URL : https://patchwork.freedesktop.org/series/50801/ State : success == Summary == = CI Bug Log - changes from CI_DRM_4961_full -> Patchwork_10413_full = == Summary - WARNING == Minor unknown changes coming with Patchwork_10413_full need to be verified manually. If you think the reported changes have nothing to do with the changes introduced in Patchwork_10413_full, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI. == Possible new issues == Here are the unknown changes that may have been introduced in Patchwork_10413_full: === IGT changes === ==== Warnings ==== igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-shrfb-draw-render: shard-snb: SKIP -> PASS igt@perf_pmu@rc6: shard-kbl: PASS -> SKIP == Known issues == Here are the changes found in Patchwork_10413_full that come from known issues: === IGT changes === ==== Issues hit ==== igt@gem_exec_schedule@pi-ringfull-vebox: shard-skl: NOTRUN -> FAIL (fdo#103158) igt@gem_ppgtt@blt-vs-render-ctxn: shard-skl: NOTRUN -> TIMEOUT (fdo#108039) igt@kms_busy@extended-modeset-hang-newfb-render-a: shard-skl: NOTRUN -> DMESG-WARN (fdo#107956) igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-shrfb-draw-render: shard-glk: PASS -> FAIL (fdo#103167) igt@kms_panel_fitting@legacy: shard-skl: NOTRUN -> FAIL (fdo#105456) {igt@kms_plane_alpha_blend@pipe-a-alpha-transparant-fb}: shard-skl: NOTRUN -> FAIL (fdo#108145) +1 {igt@kms_plane_alpha_blend@pipe-b-coverage-7efc}: shard-skl: NOTRUN -> FAIL (fdo#108146) igt@kms_setmode@basic: shard-hsw: PASS -> FAIL (fdo#99912) igt@pm_rpm@debugfs-forcewake-user: shard-skl: PASS -> INCOMPLETE (fdo#107807) igt@pm_rpm@gem-idle: shard-skl: NOTRUN -> INCOMPLETE (fdo#107807) ==== Possible fixes ==== igt@drv_suspend@debugfs-reader: shard-skl: INCOMPLETE (fdo#104108, fdo#107773) -> PASS igt@kms_busy@extended-modeset-hang-newfb-render-a: shard-snb: DMESG-WARN (fdo#107956) -> PASS igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-move: shard-apl: FAIL (fdo#103167) -> PASS igt@kms_plane_multiple@atomic-pipe-b-tiling-y: shard-glk: FAIL (fdo#103166) -> PASS igt@kms_setmode@basic: shard-kbl: FAIL (fdo#99912) -> PASS igt@pm_rpm@gem-mmap-cpu: shard-skl: INCOMPLETE (fdo#107807) -> PASS {name}: This element is suppressed. This means it is ignored when computing the status of the difference (SUCCESS, WARNING, or FAILURE). fdo#103158 https://bugs.freedesktop.org/show_bug.cgi?id=103158 fdo#103166 https://bugs.freedesktop.org/show_bug.cgi?id=103166 fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167 fdo#104108 https://bugs.freedesktop.org/show_bug.cgi?id=104108 fdo#105456 https://bugs.freedesktop.org/show_bug.cgi?id=105456 fdo#107773 https://bugs.freedesktop.org/show_bug.cgi?id=107773 fdo#107807 https://bugs.freedesktop.org/show_bug.cgi?id=107807 fdo#107956 https://bugs.freedesktop.org/show_bug.cgi?id=107956 fdo#108039 https://bugs.freedesktop.org/show_bug.cgi?id=108039 fdo#108145 https://bugs.freedesktop.org/show_bug.cgi?id=108145 fdo#108146 https://bugs.freedesktop.org/show_bug.cgi?id=108146 fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912 == Participating hosts (6 -> 6) == No changes in participating hosts == Build changes == * Linux: CI_DRM_4961 -> Patchwork_10413 CI_DRM_4961: 1b9d983587107509e70d14509fcd304b19ae0ce0 @ git://anongit.freedesktop.org/gfx-ci/linux IGT_4673: 54cb1aeb4e50dea9f3abae632e317875d147c4ab @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools Patchwork_10413: 2f79f218c3ba344e17eb939a94f45b144070967d @ git://anongit.freedesktop.org/gfx-ci/linux piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit == Logs == For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_10413/shards.html _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2] drm/i915/selftests: Check for hangs mid context execution tests 2018-10-10 12:51 [PATCH] drm/i915/selftests: Check for hangs mid context execution tests Chris Wilson 2018-10-10 13:51 ` ✓ Fi.CI.BAT: success for " Patchwork 2018-10-10 18:37 ` ✓ Fi.CI.IGT: " Patchwork @ 2018-10-12 12:24 ` Chris Wilson 2018-10-26 11:14 ` Tvrtko Ursulin 2018-10-12 13:09 ` ✗ Fi.CI.BAT: failure for drm/i915/selftests: Check for hangs mid context execution tests (rev2) Patchwork 3 siblings, 1 reply; 7+ messages in thread From: Chris Wilson @ 2018-10-12 12:24 UTC (permalink / raw) To: intel-gfx Use the live_test struct to record the reset count before and compare it at the end of the test to assert that no mystery hang occurred during the test. v2: Check per-engine resets as well Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> --- .../gpu/drm/i915/selftests/i915_gem_context.c | 51 +++++++++++++++---- 1 file changed, 41 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/i915/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/selftests/i915_gem_context.c index 913c0f83f86a..1be3b67a7c48 100644 --- a/drivers/gpu/drm/i915/selftests/i915_gem_context.c +++ b/drivers/gpu/drm/i915/selftests/i915_gem_context.c @@ -39,7 +39,8 @@ struct live_test { const char *func; const char *name; - unsigned int reset_count; + unsigned int reset_global; + unsigned int reset_engine[I915_NUM_ENGINES]; }; static int begin_live_test(struct live_test *t, @@ -47,6 +48,8 @@ static int begin_live_test(struct live_test *t, const char *func, const char *name) { + struct intel_engine_cs *engine; + enum intel_engine_id id; int err; t->i915 = i915; @@ -63,7 +66,11 @@ static int begin_live_test(struct live_test *t, } i915->gpu_error.missed_irq_rings = 0; - t->reset_count = i915_reset_count(&i915->gpu_error); + t->reset_global = i915_reset_count(&i915->gpu_error); + + for_each_engine(engine, i915, id) + t->reset_engine[id] = + i915_reset_engine_count(&i915->gpu_error, engine); return 0; } @@ -71,14 +78,28 @@ static int begin_live_test(struct live_test *t, static int end_live_test(struct live_test *t) { struct drm_i915_private *i915 = t->i915; + struct intel_engine_cs *engine; + enum intel_engine_id id; if (igt_flush_test(i915, I915_WAIT_LOCKED)) return -EIO; - if (t->reset_count != i915_reset_count(&i915->gpu_error)) { + if (t->reset_global != i915_reset_count(&i915->gpu_error)) { pr_err("%s(%s): GPU was reset %d times!\n", t->func, t->name, - i915_reset_count(&i915->gpu_error) - t->reset_count); + i915_reset_count(&i915->gpu_error) - t->reset_global); + return -EIO; + } + + for_each_engine(engine, i915, id) { + if (t->reset_engine[id] == + i915_reset_engine_count(&i915->gpu_error, engine)) + continue; + + pr_err("%s(%s): engine '%s' was reset %d times!\n", + t->func, t->name, engine->name, + i915_reset_engine_count(&i915->gpu_error, engine) - + t->reset_engine[id]); return -EIO; } @@ -531,10 +552,11 @@ static int igt_ctx_exec(void *arg) { struct drm_i915_private *i915 = arg; struct drm_i915_gem_object *obj = NULL; + unsigned long ncontexts, ndwords, dw; struct drm_file *file; IGT_TIMEOUT(end_time); LIST_HEAD(objects); - unsigned long ncontexts, ndwords, dw; + struct live_test t; int err = -ENODEV; /* @@ -552,6 +574,10 @@ static int igt_ctx_exec(void *arg) mutex_lock(&i915->drm.struct_mutex); + err = begin_live_test(&t, i915, __func__, ""); + if (err) + goto out_unlock; + ncontexts = 0; ndwords = 0; dw = 0; @@ -616,7 +642,7 @@ static int igt_ctx_exec(void *arg) } out_unlock: - if (igt_flush_test(i915, I915_WAIT_LOCKED)) + if (end_live_test(&t)) err = -EIO; mutex_unlock(&i915->drm.struct_mutex); @@ -628,13 +654,14 @@ static int igt_ctx_readonly(void *arg) { struct drm_i915_private *i915 = arg; struct drm_i915_gem_object *obj = NULL; + struct i915_gem_context *ctx; + struct i915_hw_ppgtt *ppgtt; + unsigned long ndwords, dw; struct drm_file *file; I915_RND_STATE(prng); IGT_TIMEOUT(end_time); LIST_HEAD(objects); - struct i915_gem_context *ctx; - struct i915_hw_ppgtt *ppgtt; - unsigned long ndwords, dw; + struct live_test t; int err = -ENODEV; /* @@ -649,6 +676,10 @@ static int igt_ctx_readonly(void *arg) mutex_lock(&i915->drm.struct_mutex); + err = begin_live_test(&t, i915, __func__, ""); + if (err) + goto out_unlock; + ctx = i915_gem_create_context(i915, file->driver_priv); if (IS_ERR(ctx)) { err = PTR_ERR(ctx); @@ -721,7 +752,7 @@ static int igt_ctx_readonly(void *arg) } out_unlock: - if (igt_flush_test(i915, I915_WAIT_LOCKED)) + if (end_live_test(&t)) err = -EIO; mutex_unlock(&i915->drm.struct_mutex); -- 2.19.1 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2] drm/i915/selftests: Check for hangs mid context execution tests 2018-10-12 12:24 ` [PATCH v2] " Chris Wilson @ 2018-10-26 11:14 ` Tvrtko Ursulin 2018-10-26 11:44 ` Chris Wilson 0 siblings, 1 reply; 7+ messages in thread From: Tvrtko Ursulin @ 2018-10-26 11:14 UTC (permalink / raw) To: Chris Wilson, intel-gfx On 12/10/2018 13:24, Chris Wilson wrote: > Use the live_test struct to record the reset count before and compare it > at the end of the test to assert that no mystery hang occurred during the > test. > > v2: Check per-engine resets as well > > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> > Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> > --- > .../gpu/drm/i915/selftests/i915_gem_context.c | 51 +++++++++++++++---- > 1 file changed, 41 insertions(+), 10 deletions(-) > > diff --git a/drivers/gpu/drm/i915/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/selftests/i915_gem_context.c > index 913c0f83f86a..1be3b67a7c48 100644 > --- a/drivers/gpu/drm/i915/selftests/i915_gem_context.c > +++ b/drivers/gpu/drm/i915/selftests/i915_gem_context.c > @@ -39,7 +39,8 @@ struct live_test { > const char *func; > const char *name; > > - unsigned int reset_count; > + unsigned int reset_global; > + unsigned int reset_engine[I915_NUM_ENGINES]; > }; > > static int begin_live_test(struct live_test *t, > @@ -47,6 +48,8 @@ static int begin_live_test(struct live_test *t, > const char *func, > const char *name) > { > + struct intel_engine_cs *engine; > + enum intel_engine_id id; > int err; > > t->i915 = i915; > @@ -63,7 +66,11 @@ static int begin_live_test(struct live_test *t, > } > > i915->gpu_error.missed_irq_rings = 0; > - t->reset_count = i915_reset_count(&i915->gpu_error); > + t->reset_global = i915_reset_count(&i915->gpu_error); > + > + for_each_engine(engine, i915, id) > + t->reset_engine[id] = > + i915_reset_engine_count(&i915->gpu_error, engine); > > return 0; > } > @@ -71,14 +78,28 @@ static int begin_live_test(struct live_test *t, > static int end_live_test(struct live_test *t) > { > struct drm_i915_private *i915 = t->i915; > + struct intel_engine_cs *engine; > + enum intel_engine_id id; > > if (igt_flush_test(i915, I915_WAIT_LOCKED)) > return -EIO; > > - if (t->reset_count != i915_reset_count(&i915->gpu_error)) { > + if (t->reset_global != i915_reset_count(&i915->gpu_error)) { > pr_err("%s(%s): GPU was reset %d times!\n", > t->func, t->name, > - i915_reset_count(&i915->gpu_error) - t->reset_count); > + i915_reset_count(&i915->gpu_error) - t->reset_global); > + return -EIO; > + } > + > + for_each_engine(engine, i915, id) { > + if (t->reset_engine[id] == > + i915_reset_engine_count(&i915->gpu_error, engine)) > + continue; > + > + pr_err("%s(%s): engine '%s' was reset %d times!\n", > + t->func, t->name, engine->name, > + i915_reset_engine_count(&i915->gpu_error, engine) - > + t->reset_engine[id]); > return -EIO; > } > > @@ -531,10 +552,11 @@ static int igt_ctx_exec(void *arg) > { > struct drm_i915_private *i915 = arg; > struct drm_i915_gem_object *obj = NULL; > + unsigned long ncontexts, ndwords, dw; > struct drm_file *file; > IGT_TIMEOUT(end_time); > LIST_HEAD(objects); > - unsigned long ncontexts, ndwords, dw; > + struct live_test t; > int err = -ENODEV; > > /* > @@ -552,6 +574,10 @@ static int igt_ctx_exec(void *arg) > > mutex_lock(&i915->drm.struct_mutex); > > + err = begin_live_test(&t, i915, __func__, ""); > + if (err) > + goto out_unlock; > + > ncontexts = 0; > ndwords = 0; > dw = 0; > @@ -616,7 +642,7 @@ static int igt_ctx_exec(void *arg) > } > > out_unlock: > - if (igt_flush_test(i915, I915_WAIT_LOCKED)) > + if (end_live_test(&t)) > err = -EIO; > mutex_unlock(&i915->drm.struct_mutex); > > @@ -628,13 +654,14 @@ static int igt_ctx_readonly(void *arg) > { > struct drm_i915_private *i915 = arg; > struct drm_i915_gem_object *obj = NULL; > + struct i915_gem_context *ctx; > + struct i915_hw_ppgtt *ppgtt; > + unsigned long ndwords, dw; > struct drm_file *file; > I915_RND_STATE(prng); > IGT_TIMEOUT(end_time); > LIST_HEAD(objects); > - struct i915_gem_context *ctx; > - struct i915_hw_ppgtt *ppgtt; > - unsigned long ndwords, dw; > + struct live_test t; > int err = -ENODEV; > > /* > @@ -649,6 +676,10 @@ static int igt_ctx_readonly(void *arg) > > mutex_lock(&i915->drm.struct_mutex); > > + err = begin_live_test(&t, i915, __func__, ""); > + if (err) > + goto out_unlock; > + > ctx = i915_gem_create_context(i915, file->driver_priv); > if (IS_ERR(ctx)) { > err = PTR_ERR(ctx); > @@ -721,7 +752,7 @@ static int igt_ctx_readonly(void *arg) > } > > out_unlock: > - if (igt_flush_test(i915, I915_WAIT_LOCKED)) > + if (end_live_test(&t)) > err = -EIO; > mutex_unlock(&i915->drm.struct_mutex); > > 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] 7+ messages in thread
* Re: [PATCH v2] drm/i915/selftests: Check for hangs mid context execution tests 2018-10-26 11:14 ` Tvrtko Ursulin @ 2018-10-26 11:44 ` Chris Wilson 0 siblings, 0 replies; 7+ messages in thread From: Chris Wilson @ 2018-10-26 11:44 UTC (permalink / raw) To: Tvrtko Ursulin, intel-gfx Quoting Tvrtko Ursulin (2018-10-26 12:14:31) > > On 12/10/2018 13:24, Chris Wilson wrote: > > Use the live_test struct to record the reset count before and compare it > > at the end of the test to assert that no mystery hang occurred during the > > test. > > > > v2: Check per-engine resets as well > > > > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> > > Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> > > --- > > .../gpu/drm/i915/selftests/i915_gem_context.c | 51 +++++++++++++++---- > > 1 file changed, 41 insertions(+), 10 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/selftests/i915_gem_context.c > > index 913c0f83f86a..1be3b67a7c48 100644 > > --- a/drivers/gpu/drm/i915/selftests/i915_gem_context.c > > +++ b/drivers/gpu/drm/i915/selftests/i915_gem_context.c > > @@ -39,7 +39,8 @@ struct live_test { > > const char *func; > > const char *name; > > > > - unsigned int reset_count; > > + unsigned int reset_global; > > + unsigned int reset_engine[I915_NUM_ENGINES]; > > }; > > > > static int begin_live_test(struct live_test *t, > > @@ -47,6 +48,8 @@ static int begin_live_test(struct live_test *t, > > const char *func, > > const char *name) > > { > > + struct intel_engine_cs *engine; > > + enum intel_engine_id id; > > int err; > > > > t->i915 = i915; > > @@ -63,7 +66,11 @@ static int begin_live_test(struct live_test *t, > > } > > > > i915->gpu_error.missed_irq_rings = 0; > > - t->reset_count = i915_reset_count(&i915->gpu_error); > > + t->reset_global = i915_reset_count(&i915->gpu_error); > > + > > + for_each_engine(engine, i915, id) > > + t->reset_engine[id] = > > + i915_reset_engine_count(&i915->gpu_error, engine); > > > > return 0; > > } > > @@ -71,14 +78,28 @@ static int begin_live_test(struct live_test *t, > > static int end_live_test(struct live_test *t) > > { > > struct drm_i915_private *i915 = t->i915; > > + struct intel_engine_cs *engine; > > + enum intel_engine_id id; > > > > if (igt_flush_test(i915, I915_WAIT_LOCKED)) > > return -EIO; > > > > - if (t->reset_count != i915_reset_count(&i915->gpu_error)) { > > + if (t->reset_global != i915_reset_count(&i915->gpu_error)) { > > pr_err("%s(%s): GPU was reset %d times!\n", > > t->func, t->name, > > - i915_reset_count(&i915->gpu_error) - t->reset_count); > > + i915_reset_count(&i915->gpu_error) - t->reset_global); > > + return -EIO; > > + } > > + > > + for_each_engine(engine, i915, id) { > > + if (t->reset_engine[id] == > > + i915_reset_engine_count(&i915->gpu_error, engine)) > > + continue; > > + > > + pr_err("%s(%s): engine '%s' was reset %d times!\n", > > + t->func, t->name, engine->name, > > + i915_reset_engine_count(&i915->gpu_error, engine) - > > + t->reset_engine[id]); > > return -EIO; > > } > > > > @@ -531,10 +552,11 @@ static int igt_ctx_exec(void *arg) > > { > > struct drm_i915_private *i915 = arg; > > struct drm_i915_gem_object *obj = NULL; > > + unsigned long ncontexts, ndwords, dw; > > struct drm_file *file; > > IGT_TIMEOUT(end_time); > > LIST_HEAD(objects); > > - unsigned long ncontexts, ndwords, dw; > > + struct live_test t; > > int err = -ENODEV; > > > > /* > > @@ -552,6 +574,10 @@ static int igt_ctx_exec(void *arg) > > > > mutex_lock(&i915->drm.struct_mutex); > > > > + err = begin_live_test(&t, i915, __func__, ""); > > + if (err) > > + goto out_unlock; > > + > > ncontexts = 0; > > ndwords = 0; > > dw = 0; > > @@ -616,7 +642,7 @@ static int igt_ctx_exec(void *arg) > > } > > > > out_unlock: > > - if (igt_flush_test(i915, I915_WAIT_LOCKED)) > > + if (end_live_test(&t)) > > err = -EIO; > > mutex_unlock(&i915->drm.struct_mutex); > > > > @@ -628,13 +654,14 @@ static int igt_ctx_readonly(void *arg) > > { > > struct drm_i915_private *i915 = arg; > > struct drm_i915_gem_object *obj = NULL; > > + struct i915_gem_context *ctx; > > + struct i915_hw_ppgtt *ppgtt; > > + unsigned long ndwords, dw; > > struct drm_file *file; > > I915_RND_STATE(prng); > > IGT_TIMEOUT(end_time); > > LIST_HEAD(objects); > > - struct i915_gem_context *ctx; > > - struct i915_hw_ppgtt *ppgtt; > > - unsigned long ndwords, dw; > > + struct live_test t; > > int err = -ENODEV; > > > > /* > > @@ -649,6 +676,10 @@ static int igt_ctx_readonly(void *arg) > > > > mutex_lock(&i915->drm.struct_mutex); > > > > + err = begin_live_test(&t, i915, __func__, ""); > > + if (err) > > + goto out_unlock; > > + > > ctx = i915_gem_create_context(i915, file->driver_priv); > > if (IS_ERR(ctx)) { > > err = PTR_ERR(ctx); > > @@ -721,7 +752,7 @@ static int igt_ctx_readonly(void *arg) > > } > > > > out_unlock: > > - if (igt_flush_test(i915, I915_WAIT_LOCKED)) > > + if (end_live_test(&t)) > > err = -EIO; > > mutex_unlock(&i915->drm.struct_mutex); > > > > > > Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Ta, with any luck this will cause a deluge of bug reports about icl being broken. -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
* ✗ Fi.CI.BAT: failure for drm/i915/selftests: Check for hangs mid context execution tests (rev2) 2018-10-10 12:51 [PATCH] drm/i915/selftests: Check for hangs mid context execution tests Chris Wilson ` (2 preceding siblings ...) 2018-10-12 12:24 ` [PATCH v2] " Chris Wilson @ 2018-10-12 13:09 ` Patchwork 3 siblings, 0 replies; 7+ messages in thread From: Patchwork @ 2018-10-12 13:09 UTC (permalink / raw) To: Chris Wilson; +Cc: intel-gfx == Series Details == Series: drm/i915/selftests: Check for hangs mid context execution tests (rev2) URL : https://patchwork.freedesktop.org/series/50801/ State : failure == Summary == = CI Bug Log - changes from CI_DRM_4976 -> Patchwork_10437 = == Summary - FAILURE == Serious unknown changes coming with Patchwork_10437 absolutely need to be verified manually. If you think the reported changes have nothing to do with the changes introduced in Patchwork_10437, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI. External URL: https://patchwork.freedesktop.org/api/1.0/series/50801/revisions/2/mbox/ == Possible new issues == Here are the unknown changes that may have been introduced in Patchwork_10437: === IGT changes === ==== Possible regressions ==== igt@drv_selftest@live_contexts: fi-icl-u2: PASS -> DMESG-FAIL fi-icl-u: PASS -> DMESG-FAIL == Known issues == Here are the changes found in Patchwork_10437 that come from known issues: === IGT changes === ==== Issues hit ==== igt@debugfs_test@read_all_entries: fi-icl-u: PASS -> DMESG-WARN (fdo#107724) +1 igt@drv_selftest@live_gem: {fi-apl-guc}: NOTRUN -> INCOMPLETE (fdo#106693) igt@kms_frontbuffer_tracking@basic: fi-hsw-peppy: PASS -> DMESG-WARN (fdo#102614) igt@kms_pipe_crc_basic@suspend-read-crc-pipe-b: fi-blb-e6850: PASS -> INCOMPLETE (fdo#107718) ==== Possible fixes ==== igt@kms_flip@basic-flip-vs-modeset: fi-glk-j4005: DMESG-WARN (fdo#106097) -> PASS igt@kms_frontbuffer_tracking@basic: fi-byt-clapper: FAIL (fdo#103167) -> PASS igt@kms_pipe_crc_basic@read-crc-pipe-c: fi-skl-6700k2: FAIL (fdo#107362, fdo#103191) -> PASS igt@pm_rpm@module-reload: fi-skl-6600u: INCOMPLETE (fdo#107807) -> PASS fi-glk-j4005: FAIL (fdo#108338) -> PASS {name}: This element is suppressed. This means it is ignored when computing the status of the difference (SUCCESS, WARNING, or FAILURE). fdo#102614 https://bugs.freedesktop.org/show_bug.cgi?id=102614 fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167 fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191 fdo#106097 https://bugs.freedesktop.org/show_bug.cgi?id=106097 fdo#106693 https://bugs.freedesktop.org/show_bug.cgi?id=106693 fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362 fdo#107718 https://bugs.freedesktop.org/show_bug.cgi?id=107718 fdo#107724 https://bugs.freedesktop.org/show_bug.cgi?id=107724 fdo#107807 https://bugs.freedesktop.org/show_bug.cgi?id=107807 fdo#108338 https://bugs.freedesktop.org/show_bug.cgi?id=108338 == Participating hosts (45 -> 42) == Additional (1): fi-apl-guc Missing (4): fi-ctg-p8600 fi-ilk-m540 fi-byt-squawks fi-bsw-cyan == Build changes == * Linux: CI_DRM_4976 -> Patchwork_10437 CI_DRM_4976: dec9886eff39d38332bb5ea438b9b053d6b2177c @ git://anongit.freedesktop.org/gfx-ci/linux IGT_4674: 93871c6fb3c25e5d350c9faf36ded917174214de @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools Patchwork_10437: c7def2543d8b7ead4a76b3ea8d3a2b6dc6a770c4 @ git://anongit.freedesktop.org/gfx-ci/linux == Linux commits == c7def2543d8b drm/i915/selftests: Check for hangs mid context execution tests == Logs == For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_10437/issues.html _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-10-26 11:44 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2018-10-10 12:51 [PATCH] drm/i915/selftests: Check for hangs mid context execution tests Chris Wilson 2018-10-10 13:51 ` ✓ Fi.CI.BAT: success for " Patchwork 2018-10-10 18:37 ` ✓ Fi.CI.IGT: " Patchwork 2018-10-12 12:24 ` [PATCH v2] " Chris Wilson 2018-10-26 11:14 ` Tvrtko Ursulin 2018-10-26 11:44 ` Chris Wilson 2018-10-12 13:09 ` ✗ Fi.CI.BAT: failure for drm/i915/selftests: Check for hangs mid context execution tests (rev2) 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.