[PATCH blktests v2 00/13] nvme: prepare for ANA support
Shin'ichiro Kawasaki
shinichiro.kawasaki at wdc.com
Tue Oct 29 23:51:36 PDT 2024
Hannes reworked the nvme test group scripts to support ANA, or Asymmetric
Namespace Access. This work is tracked with GitHub PR 146 [1]. The amount of
change is large, then I split them into a few series for easier review. This is
the first series, which prepares for the ANA support. Review comments will be
appreciated. It consists of a number of improvements, such as port handling
improvements, helper function simplification, code readability improvements, and
so on.
[1] https://github.com/osandov/blktests/pull/146
Most of the patches were authored by Hannes. On top of that, I added 5 patches:
- 4th 5th 6th: fix issues the 3rd patch caused
- 11th: fix an issue the 10th patch caused
The 3rd patch caused the failure of the test case nvme/037 with fc transport.
I found the following change for the test case avoids the failure, which
adds short waits after nvme disconnect and target cleanup. I expect Daniel to
follow this issue (thanks!).
diff --git a/tests/nvme/037 b/tests/nvme/037
index 33a6857..e00f632 100755
--- a/tests/nvme/037
+++ b/tests/nvme/037
@@ -36,7 +36,13 @@ test_device() {
_nvme_disconnect_subsys \
--subsysnqn "${subsys}${i}" >>"${FULL}" 2>&1
+ if [[ ${nvme_trtype} == fc ]]; then
+ sleep .1
+ fi
_nvmet_passthru_target_cleanup --subsysnqn "${subsys}${i}"
+ if [[ ${nvme_trtype} == fc ]]; then
+ sleep .1
+ fi
if [[ -z "$nsdev" ]]; then
echo "FAIL: Failed to find passthru target namespace"
Changes from v1:
* 3rd: Improved commit message per review comment
* 10th: Introduced "local -n" nameref
* 11th: Use "--port none" instead of "--no_port"
* 11th: Improved condition branches in _get_nvmet_port_params()
* Dropped 12th patch, which removed bash "local -n" nameref feature usage
* Dropped 13th patch, which should be reviewed later
Hannes Reinecke (9):
nvme/038: use nvme_trtype instead of hardcoding
nvme, md/001: make trtype argument to _create_nvmet_port() optional
nvme: sanitize transport parameter in _create_nvmet_port()
nvme: return error from _find_nvme_ns()
nvme: simplify _get_nvmet_ports()
nvme: check for controller device in _nvme_connect_subsys()
nvme: pass in port parameter to _nvme_connect_subsys()
common/nvme, nvme/{016,017,052}: improve _create_nvmet_ns()
nvme, md/001: support only long options for _create_nvmet_subsystem()
Shin'ichiro Kawasaki (4):
nvme: introduce wwnn/wwpn helper functions
nvme/{rc,002,016,017,030}: pass port ID to genctr helper functions
nvme: fix fc port clean up failure
common/nvme, nvme/003: specify "--port none" to _nvme_connect_subsys()
common/nvme | 271 +++++++++++++++++++++++++++++++++++--------------
tests/md/001 | 6 +-
tests/nvme/002 | 5 +-
tests/nvme/003 | 3 +-
tests/nvme/016 | 13 ++-
tests/nvme/017 | 14 ++-
tests/nvme/030 | 15 +--
tests/nvme/031 | 2 +-
tests/nvme/038 | 2 +-
tests/nvme/052 | 8 +-
tests/nvme/rc | 41 +++++---
11 files changed, 257 insertions(+), 123 deletions(-)
--
2.45.2
More information about the Linux-nvme
mailing list