Spdk/examples/nvme
John Levon a6aaf848a5 nvme/fio_plugin: fix race during startup
We can crash with spdk_nvme_qpair_process_completions(qpair=0x0) when
called from spdk_fio_getevents(). This was observed when passing more
than two namespaces to an fio job.

This is because this callback can be called concurrently with
spdk_fio_open(), which assigns ->qpair. We'll just skip any
non-initialized qpairs in the processing loop, as eventually
spdk_fio_open() will set them.

Fixes: "f69367c78 fio_nvme: defer qpair allocation to file_open callback"

Signed-off-by: John Levon <john.levon@nutanix.com>
Change-Id: Ie8f1ac37726e202bb971ffeb497f9e32656392aa
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12338
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2022-04-26 07:46:30 +00:00
..
abort examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
arbitration examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
cmb_copy examples/nvme/cmb_copy: exit the test tool if no controller found 2021-10-20 07:24:47 +00:00
discovery_aer examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
fio_plugin nvme/fio_plugin: fix race during startup 2022-04-26 07:46:30 +00:00
hello_world examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
hotplug examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
identify examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
nvme_manage examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
perf nvme: Prioritize user provided trstring for transport lookup 2022-03-31 10:31:20 +00:00
pmr_persistence nvme: Add spdk_nvme_detach_poll() to simplify a common use case 2021-06-30 22:54:19 +00:00
reconnect examples/nvme: add missed spdk_env_fini() when exiting 2022-01-11 14:19:05 +00:00
Makefile examples: add discovery_aer 2021-12-20 18:12:41 +00:00