Spdk/test/nvme
Tomasz Zawadzki 14ce25ab00 test/cuse: wait for device after reset
This patch adds waitforblk() after rebinding the driver.
If timing was unfortunate, it was possible to issue
id-ctrlr command to a device that was not yet ready.
Meaning the support for fw command was not read properly.

No error was reported due to "set +e", so this patch moves
it till after id-ctrlr.

Example of the error:
# get_nvme_ctrlr_from_bdf 0000:82:00.0
# readlink -f /sys/class/nvme/nvme9
# grep 0000:82:00.0/nvme/nvme
# bdf_sysfs_path=/sys/devices/pci0000:80/0000:80:03.0/0000:82:00.0/nvme/nvme9
# [[ -z /sys/devices/pci0000:80/0000:80:03.0/0000:82:00.0/nvme/nvme9 ]]
# basename /sys/devices/pci0000:80/0000:80:03.0/0000:82:00.0/nvme/nvme9
# printf '%s\n' nvme9
# nvme_name=nvme9
# [[ -z nvme9 ]]
# set +e
# ctrlr=/dev/nvme9
# ns=/dev/nvme9n1
# /usr/local/src/nvme-cli/nvme id-ctrl /dev/nvme9
# grep oacs
# cut -d: -f2
/dev/nvme9: Resource temporarily unavailable

Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Change-Id: I5728a5062cd553eb39d18d9869fdf56319a27777
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/2950
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
2020-07-08 07:55:33 +00:00
..
aer lib/nvme: add spdk_nvme_transport_available_by_name 2020-01-16 09:10:38 +00:00
cuse test/cuse: wait for device after reset 2020-07-08 07:55:33 +00:00
deallocated_value test/nvme/deallocated_value: switch to spdk_*malloc(). 2019-07-05 03:48:51 +00:00
e2edp test/nvme_dp: return failure correctly when test it in CI 2020-06-12 15:40:22 +00:00
err_injection nvme: replace cdw10 with specific union command 2019-12-06 14:43:41 +00:00
overhead test/nvme: Increment current_queue_depth only if I/O submission succeeded 2020-05-29 14:58:30 +00:00
perf build: Example applications build to build/example 2020-06-15 15:27:16 +00:00
reserve test/nvme_reserve: set host identifier at runtime 2020-06-15 15:27:50 +00:00
reset test/nvme: Increment current_queue_depth only if I/O submission succeeded 2020-05-29 14:58:30 +00:00
sgl test/nvme/sgl: switch to spdk_*malloc(). 2019-07-16 10:51:47 +00:00
startup test/nvme: Add nvme startup tool. 2019-10-23 17:03:56 +00:00
hotplug.sh autotest: always test against SPDK shared objects 2020-07-01 07:50:27 +00:00
hw_hotplug.sh build: Example applications build to build/example 2020-06-15 15:27:16 +00:00
Makefile test/nvme: dynamic nvme cuse devices update test 2020-06-05 09:01:44 +00:00
nvme_opal.sh build: Output executables from the app directory to build/bin 2020-06-15 15:27:16 +00:00
nvme_rpc.sh build: Output executables from the app directory to build/bin 2020-06-15 15:27:16 +00:00
nvme.sh test/nvme.sh: rewrite nvme_fio test to find namespaces using identify 2020-06-18 07:27:51 +00:00
spdk_nvme_cli.sh test/common: move nvme-cli compilation to common script 2020-07-06 23:22:59 +00:00