[PATCH] tests/xe_spin_batch: Add spin-timestamp-check
Zbigniew Kempczyński
zbigniew.kempczynski at intel.com
Thu Nov 7 07:35:45 UTC 2024
On Wed, Nov 06, 2024 at 11:08:20AM -0600, Lucas De Marchi wrote:
<cut>
> > +/**
> > + * SUBTEST: spin-timestamp-check
> > + * Description: Intiate gt reset then check the timestamp register for each engine.
> > + * Test category: functionality test
> > + */
> > +static void xe_spin_timestamp_check(int fd, struct drm_xe_engine_class_instance *eci)
> > +{
> > +
> > + exec_store(fd, eci, false);
>
> what is the first exec for?
That's sanity check exec submission is working fine before we submit job
which will hang it. If you think it is not necessary it might be dropped.
I'm not sure if is possible situation so that check might point if test
prerequisites are not met (and on CI we just die on exec). But then I
think fence error code should be checked as well.
--
Zbigniew
>
> > +
> > + exec_store(fd, eci, true);
>
> please use flags instead of bool to improve readability.
>
> Lucas De Marchi
>
> > +
> > + run_spinner(fd, eci);
> > +}
> > +
> > igt_main
> > {
> > struct drm_xe_engine_class_instance *hwe;
> > @@ -343,6 +495,12 @@ igt_main
> > xe_for_each_engine_class(class)
> > xe_spin_fixed_duration(fd, gt, class, SPIN_FIX_DURATION_PREEMPT);
> >
> > + igt_subtest_with_dynamic("spin-timestamp-check")
> > + xe_for_each_engine(fd, hwe) {
> > + igt_dynamic_f("engine-%s", xe_engine_class_string(hwe->engine_class))
> > + xe_spin_timestamp_check(fd, hwe);
> > + }
> > +
> > igt_fixture
> > drm_close_driver(fd);
> > }
> > --
> > 2.34.1
> >
More information about the igt-dev
mailing list