[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1639562171-4434-1-git-send-email-xuyang2018.jy@fujitsu.com>
Date: Wed, 15 Dec 2021 17:56:09 +0800
From: Yang Xu <xuyang2018.jy@...itsu.com>
To: <linux-kselftest@...r.kernel.org>, <shuah@...nel.org>
CC: <linux-kernel@...r.kernel.org>, <naresh.kamboju@...aro.org>,
<aleksei.kodanev@...l-sw.com>, Yang Xu <xuyang2018.jy@...itsu.com>
Subject: [PATCH 1/3] selftests/zram: Remove obsolete max_comp_streams interface
Since kernel commit 43209ea2d17a ("zram: remove max_comp_streams internals"), zram has
switched to per-cpu streams. Even kernel still keep this interface for some reasons, but
writing to max_comp_stream doesn't take any effect. So remove it.
Signed-off-by: Yang Xu <xuyang2018.jy@...itsu.com>
---
tools/testing/selftests/zram/zram01.sh | 4 ----
tools/testing/selftests/zram/zram02.sh | 4 ----
tools/testing/selftests/zram/zram_lib.sh | 22 ----------------------
3 files changed, 30 deletions(-)
diff --git a/tools/testing/selftests/zram/zram01.sh b/tools/testing/selftests/zram/zram01.sh
index 114863d9fb87..28583e4ae546 100755
--- a/tools/testing/selftests/zram/zram01.sh
+++ b/tools/testing/selftests/zram/zram01.sh
@@ -15,9 +15,6 @@ ERR_CODE=0
# Test will create the following number of zram devices:
dev_num=1
-# This is a list of parameters for zram devices.
-# Number of items must be equal to 'dev_num' parameter.
-zram_max_streams="2"
# The zram sysfs node 'disksize' value can be either in bytes,
# or you can use mem suffixes. But in some old kernels, mem
@@ -72,7 +69,6 @@ zram_fill_fs()
check_prereqs
zram_load
-zram_max_streams
zram_compress_alg
zram_set_disksizes
zram_set_memlimit
diff --git a/tools/testing/selftests/zram/zram02.sh b/tools/testing/selftests/zram/zram02.sh
index e83b404807c0..d664974a1317 100755
--- a/tools/testing/selftests/zram/zram02.sh
+++ b/tools/testing/selftests/zram/zram02.sh
@@ -14,9 +14,6 @@ ERR_CODE=0
# Test will create the following number of zram devices:
dev_num=1
-# This is a list of parameters for zram devices.
-# Number of items must be equal to 'dev_num' parameter.
-zram_max_streams="2"
# The zram sysfs node 'disksize' value can be either in bytes,
# or you can use mem suffixes. But in some old kernels, mem
@@ -30,7 +27,6 @@ zram_mem_limits="1M"
check_prereqs
zram_load
-zram_max_streams
zram_set_disksizes
zram_set_memlimit
zram_makeswap
diff --git a/tools/testing/selftests/zram/zram_lib.sh b/tools/testing/selftests/zram/zram_lib.sh
index 6f872f266fd1..0c49f9d1d563 100755
--- a/tools/testing/selftests/zram/zram_lib.sh
+++ b/tools/testing/selftests/zram/zram_lib.sh
@@ -82,28 +82,6 @@ zram_load()
fi
}
-zram_max_streams()
-{
- echo "set max_comp_streams to zram device(s)"
-
- local i=0
- for max_s in $zram_max_streams; do
- local sys_path="/sys/block/zram${i}/max_comp_streams"
- echo $max_s > $sys_path || \
- echo "FAIL failed to set '$max_s' to $sys_path"
- sleep 1
- local max_streams=$(cat $sys_path)
-
- [ "$max_s" -ne "$max_streams" ] && \
- echo "FAIL can't set max_streams '$max_s', get $max_stream"
-
- i=$(($i + 1))
- echo "$sys_path = '$max_streams' ($i/$dev_num)"
- done
-
- echo "zram max streams: OK"
-}
-
zram_compress_alg()
{
echo "test that we can set compression algorithm"
--
2.23.0
Powered by blists - more mailing lists