[PATCH i-g-t 1/1] tests/intel/xe_module_load: Fixed the skipped test issue

Piatkowski, Dominik Karol dominik.karol.piatkowski at intel.com
Tue Apr 22 11:58:29 UTC 2025


Hi Sobin,

> -----Original Message-----
> From: Thomas, Sobin <sobin.thomas at intel.com>
> Sent: Tuesday, April 22, 2025 12:30 PM
> To: igt-dev at lists.freedesktop.org
> Cc: Piatkowski, Dominik Karol <dominik.karol.piatkowski at intel.com>
> Subject: [PATCH i-g-t 1/1] tests/intel/xe_module_load: Fixed the skipped test
> issue
> 
> Fixed the xe load test getting skipped by unloading the
> xe driver before loading the driver.

I am personally against this change - this is essentially making the load
test a reload test, which we already have. On top of that, test name and
documentation vs its behavior becomes misleading - this test should
only try to load the module, not reload it.

Skip does not mean failure. It means that the module is already loaded.

Thanks,
Dominik Karol 

> 
> Signed-off-by: Sobin Thomas <sobin.thomas at intel.com>
> ---
>  tests/intel/xe_module_load.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/tests/intel/xe_module_load.c b/tests/intel/xe_module_load.c
> index 83e37430f..15cbfb51f 100644
> --- a/tests/intel/xe_module_load.c
> +++ b/tests/intel/xe_module_load.c
> @@ -120,6 +120,9 @@ igt_main
>  {
>  	igt_describe("Check if xe and friends are not yet loaded, then load
> them.");
>  	igt_subtest("load") {
> +		if (igt_kmod_is_loaded("xe"))
> +			igt_xe_driver_unload();
> +
>  		for (int i = 0; unwanted_drivers[i] != NULL; i++) {
> 
> 	igt_skip_on_f(igt_kmod_is_loaded(unwanted_drivers[i]),
>  				      "%s is already loaded\n",
> unwanted_drivers[i]);
> --
> 2.34.1



More information about the igt-dev mailing list