lib-test_kmod-do-not-hardcode-depend-on-any-filesystem.patch removed from -mm tree
The quilt patch titled
Subject: lib/test_kmod: do not hardcode/depend on any filesystem
has been removed from the -mm tree. Its filename was
lib-test_kmod-do-not-hardcode-depend-on-any-filesystem.patch
This patch was dropped because it was merged into the mm-nonmm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: "Herton R. Krzesinski" <[email protected]>
Subject: lib/test_kmod: do not hardcode/depend on any filesystem
Date: Fri, 18 Apr 2025 13:50:47 -0300
Right now test_kmod has hardcoded dependencies on btrfs/xfs. That is not optimal since you end up needing to select/build them, but it is not really required since other fs could be selected for the testing. Also, we can't change the default/driver module used for testing on initialization.
Thus make it more generic: introduce two module parameters (start_driver and start_test_fs), which allow to select which modules/fs to use for the testing on test_kmod initialization. Then it's up to the user to select which modules/fs to use for testing based on his config. However, keep test_module as required default.
This way, config/modules becomes selectable as when the testing is done from selftests (userspace).
While at it, also change trigger_config_run_type, since at module initialization we already set the defaults at __kmod_config_init and should not need to do it again in test_kmod_init(), thus we can avoid to again set test_driver/test_fs.
---
lib/Kconfig.debug | 6 -- lib/test_kmod.c | 64 +++++++++++++------------- tools/testing/selftests/kmod/config | 5 -- 3 files changed, 34 insertions(+), 41 deletions(-)
lib/Kconfig.debug renamed from lib/Kconfig.debug~lib-test_kmod-do-not-hardcode-depend-on-any-filesystem +0 -6
@@ -2983,13 +2983,7 @@ config TEST_DYNAMIC_DEBUG config TEST_KMOD tristate "kmod stress tester" depends on m - depends on NETDEVICES && NET_CORE && INET # for TUN - depends on BLOCK - depends on PAGE_SIZE_LESS_THAN_256KB # for BTRFS select TEST_LKM - select XFS_FS - select TUN - select BTRFS_FS help Test the kernel's module loading mechanism: kmod. kmod implements support to load modules using the Linux kernel's usermode helper.
lib/test_kmod.c renamed from lib/test_kmod.c~lib-test_kmod-do-not-hardcode-depend-on-any-filesystem +34 -30
122 lines not on this page · raw message
tools/testing/selftests/kmod/config renamed from tools/testing/selftests/kmod/config~lib-test_kmod-do-not-hardcode-depend-on-any-filesystem +0 -5
@@ -1,7 +1,2 @@ CONFIG_TEST_KMOD=m CONFIG_TEST_LKM=m -CONFIG_XFS_FS=m - -# For the module parameter force_init_test is used -CONFIG_TUN=m -CONFIG_BTRFS_FS=m
_
Patches currently in -mm which might be from [email protected] are