[PATCH i-g-t v2 3/6] lib/kunit: Unload base KUnit module only before reloading it

Lucas De Marchi lucas.demarchi at intel.com
Wed Jan 31 22:46:59 UTC 2024


On Wed, Jan 31, 2024 at 07:03:50PM +0100, Janusz Krzysztofik wrote:
>In preparation for replacement of the current method of reloading base
>KUnit module when a new set of module parameters is needed with updating
>those parameters via sysfs, unload the module right before it is now
>reloaded with new parameters, and stop unloading it in other places.
>Follow-up patches will remove some of the code added here, but even then
>they will be shorter and more clean with that adjustment already in place.
>
>Signed-off-by: Janusz Krzysztofik <janusz.krzysztofik at linux.intel.com>
>---
> lib/igt_kmod.c | 23 ++++++++++++-----------
> 1 file changed, 12 insertions(+), 11 deletions(-)
>
>diff --git a/lib/igt_kmod.c b/lib/igt_kmod.c
>index d1091bdc79..d2c28d0a64 100644
>--- a/lib/igt_kmod.c
>+++ b/lib/igt_kmod.c
>@@ -1130,6 +1130,7 @@ static void kunit_get_tests(struct igt_list_head *tests,
> 	 * iterating over KTAP results collected from blind execution of all
> 	 * Kunit test cases provided by a Kunit test module.
> 	 */
>+	igt_ignore_warn(igt_kmod_unload("kunit", KMOD_REMOVE_FORCE));

with the rw params, we should be able to run with a built-in kunit. Will
we be able to with this call here?

Lucas De Marchi


More information about the igt-dev mailing list