Message ID | 20200615143321.14371-1-chris@chris-wilson.co.uk (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/i915/selftests: Dump engine state and trace upon hanging after reset | expand |
Chris Wilson <chris@chris-wilson.co.uk> writes: > If the engine dies after a reset, and so we fail to submit a request > but need to be interrupted by the CI runner, dump the engine state. > > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com> > --- > drivers/gpu/drm/i915/gt/selftest_hangcheck.c | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) > > diff --git a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c > index 2af66f8ffbd2..1ea4935e0eeb 100644 > --- a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c > +++ b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c > @@ -499,6 +499,21 @@ static int igt_reset_nop_engine(void *arg) > > rq = intel_context_create_request(ce); > if (IS_ERR(rq)) { > + struct drm_printer p = > + drm_info_printer(gt->i915->drm.dev); > + intel_engine_dump(engine, &p, > + "%s(%s): failed to submit request\n", > + __func__, > + engine->name); > + > + > + GEM_TRACE("%s(%s): failed to submit request\n", > + __func__, > + engine->name); > + GEM_TRACE_DUMP(); > + > + intel_gt_set_wedged(gt); > + > err = PTR_ERR(rq); > break; > } > -- > 2.20.1 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
diff --git a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c index 2af66f8ffbd2..1ea4935e0eeb 100644 --- a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c +++ b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c @@ -499,6 +499,21 @@ static int igt_reset_nop_engine(void *arg) rq = intel_context_create_request(ce); if (IS_ERR(rq)) { + struct drm_printer p = + drm_info_printer(gt->i915->drm.dev); + intel_engine_dump(engine, &p, + "%s(%s): failed to submit request\n", + __func__, + engine->name); + + + GEM_TRACE("%s(%s): failed to submit request\n", + __func__, + engine->name); + GEM_TRACE_DUMP(); + + intel_gt_set_wedged(gt); + err = PTR_ERR(rq); break; }
If the engine dies after a reset, and so we fail to submit a request but need to be interrupted by the CI runner, dump the engine state. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> --- drivers/gpu/drm/i915/gt/selftest_hangcheck.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+)