[PATCH] tests/nvme: Set clear_ids for passthru targets

Alan Adamson alan.adamson at oracle.com
Tue Jul 5 13:56:31 PDT 2022


This allows to connect to passthru targets when the client and target
are on the same host.

Signed-off-by: Alan Adamson <alan.adamson at oracle.com>
---
 tests/nvme/rc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tests/nvme/rc b/tests/nvme/rc
index 4bebbc762cbb..5e50e69fb3f0 100644
--- a/tests/nvme/rc
+++ b/tests/nvme/rc
@@ -303,6 +303,9 @@ _create_nvmet_passthru() {
 
 	_test_dev_nvme_ctrl > "${passthru_path}/device_path"
 	echo 1 > "${passthru_path}/enable"
+	if [ -f "${passthru_path}/clear_ids" ]; then
+		echo 1 > "${passthru_path}/clear_ids"
+	fi
 }
 
 _remove_nvmet_passhtru() {
-- 
2.31.1




More information about the Linux-nvme mailing list