[igt-dev] [PATCH igt 08/16] igt/gem_exec_schedule: Replace constant 16 with its magic macro

Joonas Lahtinen joonas.lahtinen at linux.intel.com
Tue Feb 20 10:57:44 UTC 2018


Quoting Chris Wilson (2018-02-20 10:45:12)
> @@ -398,7 +399,7 @@ static void preempt(int fd, unsigned ring, unsigned flags)
>                 igt_assert(gem_bo_busy(fd, spin[0]->handle));
>         }
>  
> -       for (int n = 0; n < 16; n++)
> +       for (int n = 0; n < MAX_ELSP_QLEN; n++)
>                 igt_spin_batch_free(fd, spin[n]);

ARRAY_SIZE() seems more appropriate in the for loops. Seems like you've
opted not to use it so much, why so?

> @@ -450,6 +453,7 @@ static void preempt_other(int fd, unsigned ring)
>                     result, (n + 1)*sizeof(uint32_t), n + 1,
>                     0, I915_GEM_DOMAIN_RENDER);
>  
> +       igt_debugfs_dump(fd, "i915_engine_info");

Lost and afraid hunk here? You can have my R-b for it in separate patch.

Regards, Joonas


More information about the igt-dev mailing list