Skip to content

Commit 149a6a4

Browse files
author
Herton R. Krzesinski
committed
redhat: enable test_kmod, test_module and install kmod selftests
JIRA: https://issues.redhat.com/browse/RHEL-94012 Upstream Status: ARK commit 88311ff4b85b556cff60da81d1dbe095b2190b8e commit 88311ff4b85b556cff60da81d1dbe095b2190b8e Author: Herton R. Krzesinski <herton@redhat.com> Date: Fri Jun 6 12:20:59 2025 -0300 redhat: enable test_kmod, test_module and install kmod selftests Tested: installed both -modules-internal and selftests-internal sub packages and run the kmod.sh selftest with an unloaded fs module chosen with DEFAULT_KMOD_FS variable, with the same kernel build booted. Tested on both rawhide and eln. To be able to test the module subsystem in the kernel, enable the modules used by kmod selftests. Given current filters, those enabled modules already land automatically within the modules-internal subpackage. Also, install the kmod selftest script used for testing. Signed-off-by: Herton R. Krzesinski <herton@redhat.com> Conflicts: - redhat/kernel.spec.template: 1 hunk modified Assisted-by: Patchpal AI Signed-off-by: Herton R. Krzesinski <herton@redhat.com>
1 parent 91fa32e commit 149a6a4

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
# CONFIG_TEST_KMOD is not set
1+
CONFIG_TEST_KMOD=m
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
# CONFIG_TEST_LKM is not set
1+
CONFIG_TEST_LKM=m

redhat/kernel.spec.template

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3254,7 +3254,7 @@ pushd tools/testing/selftests
32543254
%undefine _fortify_level
32553255
export CFLAGS="%{build_cflags}"
32563256

3257-
TARGETS="bpf cgroup mm net net/forwarding net/mptcp net/netfilter net/packetdrill tc-testing memfd drivers/net/bonding iommu cachestat pid_namespace rlimits timens pidfd"
3257+
TARGETS="bpf cgroup kmod mm net net/forwarding net/mptcp net/netfilter net/packetdrill tc-testing memfd drivers/net/bonding iommu cachestat pid_namespace rlimits timens pidfd"
32583258
%{make} %{?_smp_mflags} EXTRA_CFLAGS="${RPM_OPT_FLAGS}" EXTRA_CXXFLAGS="${RPM_OPT_FLAGS}" EXTRA_LDFLAGS="%{__global_ldflags}" ARCH=$Arch V=1 TARGETS="$TARGETS" SKIP_TARGETS="" $force_targets VMLINUX_H="${RPM_VMLINUX_H}"
32593259

32603260
# Restore the original level of source fortification

0 commit comments

Comments
 (0)