numam-spdk/module
Shuhei Matsumoto a22d8a530f lib/nvmf: Add an API spdk_nvmf_subsystem_add_ns_ext() to pass bdev_name
Add an new API spdk_nvmf_subsystem_add_ns_ext() to pass not bdev but
bdev_name to fix the race condition due to the time gap between
spdk_bdev_get_by_name() and spdk_bdev_open(). A pointer to a bdev is
valid only while the bdev is opened.

spdk_bdev_open() has been replaced by spdk_bdev_open_ext() but the
issue still existed.

Update the corresponding unit tests accordingly.

Then replace the internal of spdk_nvmf_subsystem_add_ns() by
spdk_nvmf_subsystem_add_ns_ext() call.

Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Change-Id: Ifcaa2121129ef22d5e61c9a8f7c640ff37a64485
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4485
Community-CI: Broadcom CI
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
2020-10-14 08:07:06 +00:00
..
accel log: simplify SPDK_LOG_REGISTER_COMPONENT 2020-10-14 08:00:35 +00:00
bdev module/bdev: Initialize global TAILQ HEAD variables at definition. 2020-10-14 08:06:25 +00:00
blob lib/bdev: Add spdk_bdev_abort API 2020-06-08 09:28:27 +00:00
blobfs log: simplify SPDK_LOG_REGISTER_COMPONENT 2020-10-14 08:00:35 +00:00
env_dpdk mk/lib: add a check that major and minor version is set for libs. 2020-05-21 09:19:00 +00:00
event lib/nvmf: Add an API spdk_nvmf_subsystem_add_ns_ext() to pass bdev_name 2020-10-14 08:07:06 +00:00
sock posix: Reorder spdk_posix_sock struct 2020-09-29 09:35:47 +00:00
Makefile global: rename copy to accel 2020-02-18 08:05:34 +00:00