[igt-dev] [PATCH i-g-t] xe_live_ktest: Use xe_live_test kernel module
Mauro Carvalho Chehab
mauro.chehab at linux.intel.com
Thu Dec 7 15:41:52 UTC 2023
On Tue, 5 Dec 2023 14:49:26 -0800
Lucas De Marchi <lucas.demarchi at intel.com> wrote:
> https://patchwork.freedesktop.org/series/126786/ groups all the live
> tests into a single kernel module. Use that module to run any of the
> tests triggered by igt.
>
> Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>
> ---
> tests/intel/xe_live_ktest.c | 15 +++++----------
> 1 file changed, 5 insertions(+), 10 deletions(-)
>
> diff --git a/tests/intel/xe_live_ktest.c b/tests/intel/xe_live_ktest.c
> index fe7b2e69f..c8bd68928 100644
> --- a/tests/intel/xe_live_ktest.c
> +++ b/tests/intel/xe_live_ktest.c
> @@ -19,15 +19,10 @@
> * Functionality: migrate
> */
>
> -struct kunit_tests {
> - const char *kunit;
> - const char *name;
> -};
> -
> -static const struct kunit_tests live_tests[] = {
> - { "xe_bo_test", "bo" },
> - { "xe_dma_buf_test", "dmabuf" },
> - { "xe_migrate_test", "migrate" },
> +static const char *live_tests[] = {
> + "bo",
> + "dmabuf",
> + "migrate",
> };
>
> igt_main
> @@ -35,5 +30,5 @@ igt_main
> int i;
>
> for (i = 0; i < ARRAY_SIZE(live_tests); i++)
> - igt_kunit(live_tests[i].kunit, live_tests[i].name, NULL);
> + igt_kunit("xe_live_test", live_tests[i], NULL);
This loop will modprobe xe_live_test the times. Just do something
like:
igt_kunit("xe_live_test", "live_tests", NULL);
> }
Regards,
Mauro
More information about the igt-dev
mailing list