From 65cf98f90ab65d373438b58d660769a3fbb3873b Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Thu, 7 Feb 2019 01:13:54 +0000 Subject: [PATCH 1/2] scst_sysfs: Increase latency measurement suspend timeout from 1/HZ to 10 s git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7904 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/src/scst_sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scst/src/scst_sysfs.c b/scst/src/scst_sysfs.c index 2ed8ecbeb..3542e05f1 100644 --- a/scst/src/scst_sysfs.c +++ b/scst/src/scst_sysfs.c @@ -6925,7 +6925,7 @@ static ssize_t scst_measure_latency_store(struct kobject *kobj, val = !!val; - res = scst_suspend_activity(true); + res = scst_suspend_activity(10 * HZ); if (res) goto out; res = mutex_lock_interruptible(&scst_mutex); From 814aed2eefa2b321f14aaad296ea4fe8967d5be1 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Thu, 7 Feb 2019 01:43:16 +0000 Subject: [PATCH 2/2] README: Make instructions to retrieve latency information more generic git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7905 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/README | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scst/README b/scst/README index f76fa3370..dc1cd0cfb 100644 --- a/scst/README +++ b/scst/README @@ -456,7 +456,8 @@ following entries: $ echo 1 >/sys/kernel/scst_tgt/measure_latency $ sleep 10 # Wait until an initiator has submitted multiple I/O requests - $ cat /sys/kernel/scst_tgt/targets/ib_srpt/fe80\:0000\:0000\:0000\:0002\:c903\:00fa\:b7f2/sessions/fe80\:0000\:0000\:0000\:0002\:c903\:00a3\:4272/latency/r512 + $ (cd /sys/kernel/scst_tgt/targets && + find -name latency | xargs grep -raH .) state count min max avg stddev PARSE 219 1.3 26.6 2.2 2.5 us PREPARE_SPACE 219 0.9 10.3 1.1 0.6 us