public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH 1/3] shell: Remove old kernel version check below 3.10
@ 2022-12-27  9:20 Yang Xu
  2022-12-27  9:20 ` [LTP] [PATCH 2/3] Remove old kernel version check when using tst_kvercmp under 3.10 Yang Xu
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Yang Xu @ 2022-12-27  9:20 UTC (permalink / raw)
  To: ltp

We have raised the minimal kernel version from 3.0 to 3.10,
so remove these useless check.

Signed-off-by: Yang Xu <xuyang2018.jy@fujitsu.com>
---
 doc/shell-test-api.txt                           |  6 +++---
 .../tracing/dynamic_debug/dynamic_debug01.sh     | 16 ++++------------
 testcases/network/virt/virt_lib.sh               |  8 --------
 3 files changed, 7 insertions(+), 23 deletions(-)

diff --git a/doc/shell-test-api.txt b/doc/shell-test-api.txt
index 7f0ca02a7..df6a56874 100644
--- a/doc/shell-test-api.txt
+++ b/doc/shell-test-api.txt
@@ -661,9 +661,9 @@ if tst_kvcmp -le 4.0.0; then
 	tst_brk TCONF "Kernel newer than 4.0.0 is needed"
 fi
 
-# Exit the test if kernel is newer than 3.8 and older than 4.0.1
-if tst_kvcmp -gt 3.8 -a -lt 4.0.1; then
-	tst_brk TCONF "Kernel must be older than 3.8 or newer than 4.0.1"
+# Exit the test if kernel is newer than 3.16 and older than 4.0.1
+if tst_kvcmp -gt 3.16 -a -lt 4.0.1; then
+	tst_brk TCONF "Kernel must be older than 3.16 or newer than 4.0.1"
 fi
 -------------------------------------------------------------------------------
 
diff --git a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh
index 9d0575b90..ebb961fd9 100755
--- a/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh
+++ b/testcases/kernel/tracing/dynamic_debug/dynamic_debug01.sh
@@ -21,8 +21,7 @@ DEBUGFS_WAS_MOUNTED=0
 DEBUGFS_PATH=""
 DEBUGFS_CONTROL=""
 DYNDEBUG_STATEMENTS="./debug_statements"
-EMPTY_FLAG="-"
-NEW_INTERFACE=0
+EMPTY_FLAG="=_"
 
 mount_debugfs()
 {
@@ -55,11 +54,6 @@ setup()
 		tst_brk TBROK "Unable to find $DEBUGFS_CONTROL"
 	fi
 
-	if tst_kvcmp -ge 3.4 ; then
-		NEW_INTERFACE=1
-		EMPTY_FLAG="=_"
-	fi
-
 	grep -v "^#" "$DEBUGFS_CONTROL" > "$DYNDEBUG_STATEMENTS"
 }
 
@@ -83,10 +77,8 @@ do_all_flags()
 
 	for INPUT_LINE in $ALL_INPUTS; do
 		do_flag "+p" "$OPTION" "$INPUT_LINE"
-		if tst_kvcmp -ge 3.2 || [ $NEW_INTERFACE -eq 1 ] ; then
-			do_flag "+flmt" "$OPTION" "$INPUT_LINE"
-			do_flag "-flmt" "$OPTION" "$INPUT_LINE"
-		fi
+		do_flag "+flmt" "$OPTION" "$INPUT_LINE"
+		do_flag "-flmt" "$OPTION" "$INPUT_LINE"
 		do_flag "-p" "$OPTION" "$INPUT_LINE"
 	done
 
@@ -131,7 +123,7 @@ cleanup()
 		FLAGS_SET=$(awk -v emp="$EMPTY_FLAG" '$3 != emp' $DYNDEBUG_STATEMENTS)
 	fi
 	if [ "$FLAGS_SET" ] ; then
-		FLAG_PREFIX=$([ $NEW_INTERFACE -eq 1 ] && echo "" || echo "+")
+		FLAG_PREFIX=$(echo "")
 		/bin/echo "$FLAGS_SET" | while read -r FLAG_LINE ; do
 			/bin/echo -n "$FLAG_LINE" \
 				| awk -v prf="$FLAG_PREFIX" -F " |:" \
diff --git a/testcases/network/virt/virt_lib.sh b/testcases/network/virt/virt_lib.sh
index 98a9bb6aa..e919bc3a5 100644
--- a/testcases/network/virt/virt_lib.sh
+++ b/testcases/network/virt/virt_lib.sh
@@ -44,10 +44,6 @@ virt_lib_setup()
 {
 	case "$virt_type" in
 	vxlan|geneve)
-		if tst_kvcmp -lt "3.8"; then
-			tst_brk TCONF "test must be run with kernel 3.8 or newer"
-		fi
-
 		if [ "$TST_IPV6" ] && tst_kvcmp -lt "3.12"; then
 			tst_brk TCONF "test must be run with kernels >= 3.12"
 		fi
@@ -252,10 +248,6 @@ virt_minimize_timeout()
 
 vxlan_setup_subnet_uni()
 {
-	if tst_kvcmp -lt "3.10"; then
-		tst_brk TCONF "test must be run with kernel 3.10 or newer"
-	fi
-
 	[ "$(ip link add type $virt_type help 2>&1 | grep remote)" ] || \
 		tst_brk TCONF "iproute doesn't support remote unicast address"
 
-- 
2.31.1


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-01-04  4:59 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-27  9:20 [LTP] [PATCH 1/3] shell: Remove old kernel version check below 3.10 Yang Xu
2022-12-27  9:20 ` [LTP] [PATCH 2/3] Remove old kernel version check when using tst_kvercmp under 3.10 Yang Xu
2023-01-02 12:01   ` Petr Vorel
2022-12-27  9:20 ` [LTP] [PATCH 3/3] Remove old kernel version check when using min_kver " Yang Xu
2023-01-02 12:04   ` Petr Vorel
2023-01-02  9:37 ` [LTP] [PATCH 1/3] shell: Remove old kernel version check below 3.10 Petr Vorel
2023-01-03  5:39   ` xuyang2018.jy
2023-01-03 18:13   ` Petr Vorel
2023-01-04  4:59     ` xuyang2018.jy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox