a22d8a530f
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> |
||
---|---|---|
.. | ||
linux | ||
spdk | ||
spdk_internal | ||
Makefile |