[PATCH blktests v5 1/4] nvme/rc: Add setter for attr_qid_max

Daniel Wagner dwagner at suse.de
Wed Apr 5 08:46:27 PDT 2023


Signed-off-by: Daniel Wagner <dwagner at suse.de>
---
 tests/nvme/rc | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/tests/nvme/rc b/tests/nvme/rc
index a3c9b42d91e6..ec7678dbe09e 100644
--- a/tests/nvme/rc
+++ b/tests/nvme/rc
@@ -617,6 +617,16 @@ _set_nvmet_dhgroup() {
 	     "${cfs_path}/dhchap_dhgroup"
 }
 
+_set_nvmet_attr_qid_max() {
+	local nvmet_subsystem="$1"
+	local qid_max="$2"
+	local cfs_path="${NVMET_CFS}/subsystems/${nvmet_subsystem}"
+
+	if [[ -f "${cfs_path}/attr_qid_max" ]]; then
+		echo $qid_max > "${cfs_path}/attr_qid_max"
+	fi
+}
+
 _find_nvme_dev() {
 	local subsys=$1
 	local subsysnqn
-- 
2.40.0




More information about the Linux-nvme mailing list