From: Yi Zhang <yi.zhang@redhat.com>
To: osandov@osandov.com, bvanassche@acm.org
Cc: linux-block@vger.kernel.org, sagi@grimberg.me,
linux-nvme@lists.infradead.org
Subject: [PATCH blktests 3/5] tests/nvmeof-mp/012: fix the schedulers list
Date: Tue, 24 Nov 2020 09:04:25 +0800 [thread overview]
Message-ID: <20201124010427.18595-4-yi.zhang@redhat.com> (raw)
In-Reply-To: <20201124010427.18595-1-yi.zhang@redhat.com>
There is no cfg scheduler and new added kyber scheduler in lastest kernel,
so get the scheduler from sysfs
To reproduce it:
$ ./check nvmeof-mp/012
nvmeof-mp/012 (dm-mpath on top of multiple I/O schedulers) [passed]
runtime 5.922s ... 8.804s
$ cat results/nodev/nvmeof-mp/012.full | grep -n "Changing scheduler"
31:Changing scheduler of dm-3 from mq-deadline kyber [bfq] none into cfq failed
47:Changing scheduler of dm-3 from mq-deadline kyber [bfq] none into cfq failed
Signed-off-by: Yi Zhang <yi.zhang@redhat.com>
---
tests/nvmeof-mp/012 | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/tests/nvmeof-mp/012 b/tests/nvmeof-mp/012
index ae6a92c..96adc70 100755
--- a/tests/nvmeof-mp/012
+++ b/tests/nvmeof-mp/012
@@ -8,7 +8,7 @@ DESCRIPTION="dm-mpath on top of multiple I/O schedulers"
QUICK=1
test_io_schedulers() {
- local dev m
+ local dev m dm scheds
# Load all I/O scheduler kernel modules
for m in "/lib/modules/$(uname -r)/kernel/block/"*.ko; do
@@ -17,15 +17,17 @@ test_io_schedulers() {
for mq in y n; do
use_blk_mq ${mq} || return $?
dev=$(get_bdev 0) || return $?
- for sched in noop deadline bfq cfq; do
- set_scheduler "$(basename "$(readlink -f "${dev}")")" $sched \
+ dm=$(basename "$(readlink -f "${dev}")") || return $?
+ scheds=$(sed 's/[][]//g' /sys/block/"$dm"/queue/scheduler) || return $?
+ for sched in $scheds; do
+ set_scheduler "$dm" "$sched" \
>>"$FULL" 2>&1 || continue
echo "I/O scheduler: $sched; use_blk_mq: $mq" >>"$FULL"
run_fio --verify=md5 --rw=randwrite --bs=4K --size=64K \
--ioengine=libaio --iodepth=64 \
--iodepth_batch=32 --group_reporting --sync=1 \
--direct=1 --filename="$dev" \
- --name=${sched} --thread --numjobs=1 \
+ --name="${sched}" --thread --numjobs=1 \
--output="${RESULTS_DIR}/nvmeof-mp/012-${sched}-${mq}.txt" \
>>"$FULL" ||
return $?
--
2.21.0
_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme
next prev parent reply other threads:[~2020-11-24 1:05 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-24 1:04 [PATCH blktests 0/5] nvmeof-mp/srp/nvme-rdma misc fix and enhancement Yi Zhang
2020-11-24 1:04 ` [PATCH blktests 1/5] tests/srp/rc: update the ib_srpt module name Yi Zhang
2020-11-24 3:23 ` Bart Van Assche
2020-11-24 14:01 ` Yi Zhang
2020-11-25 3:47 ` Bart Van Assche
2020-11-25 7:36 ` Yi Zhang
2020-11-24 1:04 ` [PATCH blktests 2/5] tests/nvmeof-mp/rc: run nvmeof-mp tests if we set multipath=N Yi Zhang
2020-11-24 3:26 ` Bart Van Assche
2020-11-24 14:04 ` Yi Zhang
2020-11-25 3:51 ` Bart Van Assche
2020-11-25 7:36 ` Yi Zhang
2020-11-24 1:04 ` Yi Zhang [this message]
2020-11-24 3:28 ` [PATCH blktests 3/5] tests/nvmeof-mp/012: fix the schedulers list Bart Van Assche
2020-11-24 14:06 ` Yi Zhang
2020-11-24 1:04 ` [PATCH blktests 4/5] common/rc: _have_iproute2 fix for "ip -V" change Yi Zhang
2020-11-24 3:29 ` Bart Van Assche
2020-11-24 14:07 ` Yi Zhang
2020-11-24 1:04 ` [PATCH blktests 5/5] common/multipath-over-rdma: allow to set use_siw Yi Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201124010427.18595-4-yi.zhang@redhat.com \
--to=yi.zhang@redhat.com \
--cc=bvanassche@acm.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-nvme@lists.infradead.org \
--cc=osandov@osandov.com \
--cc=sagi@grimberg.me \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).