diff mbox series

[i-g-t] tests/gem_barrier_race: Extend support over compute engines

Message ID 20230220132445.32129-1-janusz.krzysztofik@linux.intel.com (mailing list archive)
State New, archived
Headers show
Series [i-g-t] tests/gem_barrier_race: Extend support over compute engines | expand

Commit Message

Janusz Krzysztofik Feb. 20, 2023, 1:24 p.m. UTC
This test can work not only on render engines, as its current code
suggests, but also on compute class engines.  Add them to the set of
engine classes supported by the test, in case a future platform has only
those and no RCS available.

Suggested-by: Chris Wilson <chris.p.wilson@linux.intel.com>
Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
---
 tests/i915/gem_barrier_race.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Kamil Konieczny Feb. 20, 2023, 8:49 p.m. UTC | #1
On 2023-02-20 at 14:24:45 +0100, Janusz Krzysztofik wrote:
> This test can work not only on render engines, as its current code
> suggests, but also on compute class engines.  Add them to the set of
> engine classes supported by the test, in case a future platform has only
> those and no RCS available.

Lgtm,
Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>

--
Kamil

> 
> Suggested-by: Chris Wilson <chris.p.wilson@linux.intel.com>
> Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
> ---
>  tests/i915/gem_barrier_race.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/i915/gem_barrier_race.c b/tests/i915/gem_barrier_race.c
> index 484fef85ac..053fa2069e 100644
> --- a/tests/i915/gem_barrier_race.c
> +++ b/tests/i915/gem_barrier_race.c
> @@ -142,7 +142,8 @@ igt_main
>  		struct intel_execution_engine2 *e;
>  
>  		for_each_physical_engine(fd, e) {
> -			if (e->class != I915_ENGINE_CLASS_RENDER)
> +			if (e->class != I915_ENGINE_CLASS_RENDER &&
> +			    e->class != I915_ENGINE_CLASS_COMPUTE)
>  				continue;
>  
>  			igt_dynamic(e->name)
> -- 
> 2.25.1
>
Janusz Krzysztofik Feb. 21, 2023, 8:13 a.m. UTC | #2
On Monday, 20 February 2023 21:49:46 CET Kamil Konieczny wrote:
> On 2023-02-20 at 14:24:45 +0100, Janusz Krzysztofik wrote:
> > This test can work not only on render engines, as its current code
> > suggests, but also on compute class engines.  Add them to the set of
> > engine classes supported by the test, in case a future platform has only
> > those and no RCS available.
> 
> Lgtm,
> Reviewed-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>

Thank you Kamil, pushed.

Janusz

> 
> --
> Kamil
> 
> > 
> > Suggested-by: Chris Wilson <chris.p.wilson@linux.intel.com>
> > Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik@linux.intel.com>
> > ---
> >  tests/i915/gem_barrier_race.c | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
> > 
> > diff --git a/tests/i915/gem_barrier_race.c b/tests/i915/gem_barrier_race.c
> > index 484fef85ac..053fa2069e 100644
> > --- a/tests/i915/gem_barrier_race.c
> > +++ b/tests/i915/gem_barrier_race.c
> > @@ -142,7 +142,8 @@ igt_main
> >  		struct intel_execution_engine2 *e;
> >  
> >  		for_each_physical_engine(fd, e) {
> > -			if (e->class != I915_ENGINE_CLASS_RENDER)
> > +			if (e->class != I915_ENGINE_CLASS_RENDER &&
> > +			    e->class != I915_ENGINE_CLASS_COMPUTE)
> >  				continue;
> >  
> >  			igt_dynamic(e->name)
>
diff mbox series

Patch

diff --git a/tests/i915/gem_barrier_race.c b/tests/i915/gem_barrier_race.c
index 484fef85ac..053fa2069e 100644
--- a/tests/i915/gem_barrier_race.c
+++ b/tests/i915/gem_barrier_race.c
@@ -142,7 +142,8 @@  igt_main
 		struct intel_execution_engine2 *e;
 
 		for_each_physical_engine(fd, e) {
-			if (e->class != I915_ENGINE_CLASS_RENDER)
+			if (e->class != I915_ENGINE_CLASS_RENDER &&
+			    e->class != I915_ENGINE_CLASS_COMPUTE)
 				continue;
 
 			igt_dynamic(e->name)