[Devel] [PATCH RHEL10 COMMIT] selftests: net: fib_tests.sh: skip rp_filter test if cls_basic is unavailable

Konstantin Khorenko khorenko at virtuozzo.com
Tue Dec 23 12:49:36 MSK 2025


The commit is pushed to "branch-rh10-6.12.0-55.13.1.3.x.vz10-ovz" and will appear at git at bitbucket.org:openvz/vzkernel.git
after rh10-6.12.0-55.13.1.3.26.vz10
------>
commit 51166abd05b144e2097ab62ea86833a65701bd49
Author: Aleksei Oladko <aleksey.oladko at virtuozzo.com>
Date:   Tue Dec 16 21:04:20 2025 +0000

    selftests: net: fib_tests.sh: skip rp_filter test if cls_basic is unavailable
    
    The rp_filter test in fib_tests.sh installs tc filters using the
    "basic" classifier but does not verify the corresponding kernel
    module (cls_basic) is available. On kernels built without
    CONFIG_NET_CLS_BASIC, the tc command fails and the rp_filter test
    is reported as a failure.
    
    Add a check for the presence of the cls_basic module and skip
    the rp_filter test when the classifier is not available.
    
    https://virtuozzo.atlassian.net/browse/VSTOR-120995
    
    Signed-off-by: Aleksei Oladko <aleksey.oladko at virtuozzo.com>
    
    Feature: fix selftests
---
 tools/testing/selftests/net/fib_tests.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tools/testing/selftests/net/fib_tests.sh b/tools/testing/selftests/net/fib_tests.sh
index 5f3c28fc86249..3e359cdc09b10 100755
--- a/tools/testing/selftests/net/fib_tests.sh
+++ b/tools/testing/selftests/net/fib_tests.sh
@@ -440,6 +440,8 @@ fib_rp_filter_test()
 	echo
 	echo "IPv4 rp_filter tests"
 
+	modprobe cls_basic || return $ksft_skip
+
 	setup
 
 	set -e


More information about the Devel mailing list