[PATCH I-G-T v4] tests/intel/i915_hangman: Fix spin engine hang
Mikolaj Wasiak
mikolaj.wasiak at intel.com
Mon Dec 16 14:13:43 UTC 2024
On 2024-12-16 at 13:42:37 +0000, Krzysztof Karas wrote:
Hi Krzysztof,
> Hi Mikolaj,
>
> > +static bool is_rcs_ccs(const struct intel_execution_engine2 *e)
> > +{
> > + return e->class == I915_ENGINE_CLASS_COMPUTE ||
> > + e->class == I915_ENGINE_CLASS_RENDER;
> > +}
> > +
> > static void
> > test_engine_hang(const intel_ctx_t *ctx,
> > const struct intel_execution_engine2 *e, unsigned int flags)
> > @@ -388,6 +394,10 @@ test_engine_hang(const intel_ctx_t *ctx,
> > */
> > num_ctx = 0;
> > for_each_ctx_engine(device, ctx, other) {
> > + /* Wa_14014494547:DG2 */
> > + if (IS_DG2(intel_get_drm_devid(device)) && is_rcs_ccs(other))
The test fails when both rcs and css engines run in parallel.
What I overlooked in first patch version, was case when both of
them are running as background spins (initiated exactly in loop above).
So now the test passes not only when one of the engines is tested one,
but also when the other ones are tested.
> In previous version of this patch there were also checks to confirm
> that:
> 1) the current engine is one of the two types,
Current engine doesn't matter now because even if we run test on rcs or
ccs, we will know for sure that the other one won't run in background.
The tested engine is run later in the test and not in this loop.
> 2) the engines are different.
Cc: Andi
This I'd like Andi to comment on. What this check did, was that it
allowed for tested engine to have both frozen spin and normal
background spin. Do you think that this background spin should
still be run or is it negligible?
Mikołaj
>
> > + continue;
> > +
> > local_ctx[num_ctx] = intel_ctx_create(device, &ctx->cfg);
> > context_unban(device, local_ctx[num_ctx]->id);
> > ahndN = get_reloc_ahnd(device, local_ctx[num_ctx]->id);
> > --
> > 2.47.1
> >
More information about the igt-dev
mailing list