[igt-dev] [PATCH i-g-t 37/93] tests/i915/gem_ctx_exec: Stop cloning contexts in close_race

Zbigniew Kempczyński zbigniew.kempczynski at intel.com
Thu Jun 10 15:44:23 UTC 2021


On Wed, Jun 09, 2021 at 12:36:20PM -0500, Jason Ekstrand wrote:
> Nothing in this subtest sets the set of engines on ctx0 so there's no
> point in cloning them.
> 
> Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
> ---
>  tests/i915/gem_ctx_exec.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/tests/i915/gem_ctx_exec.c b/tests/i915/gem_ctx_exec.c
> index a8616f95..6db2d598 100644
> --- a/tests/i915/gem_ctx_exec.c
> +++ b/tests/i915/gem_ctx_exec.c
> @@ -351,7 +351,7 @@ static void close_race(int i915)
>  	igt_assert(contexts != MAP_FAILED);
>  
>  	for (int child = 0; child < ncpus; child++)
> -		contexts[child] = gem_context_clone_with_engines(i915, 0);
> +		contexts[child] = gem_context_create(i915);
>  
>  	igt_fork(child, ncpus) {
>  		spin = __igt_spin_new(i915, .flags = IGT_SPIN_POLL_RUN);
> @@ -405,8 +405,7 @@ static void close_race(int i915)
>  		 */
>  		for (int child = 0; child < ncpus; child++) {
>  			gem_context_destroy(i915, contexts[child]);
> -			contexts[child] =
> -				gem_context_clone_with_engines(i915, 0);
> +			contexts[child] = gem_context_create(i915);
>  		}
>  		usleep(1000 + hars_petruska_f54_1_random_unsafe() % 2000);
>  	}
> -- 
> 2.31.1

Reviewed-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>

--
Zbigniew

> 
> _______________________________________________
> igt-dev mailing list
> igt-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev


More information about the igt-dev mailing list