bdev_nvme_delete() calls spdk_nvme_detach() in the end. However, previously spdk_nvme_detach() stub did nothing and ut_detach_ctrlr() was called separately if ctrlr wass attached by ut_detach_ctrlr(). This was to differentiate the two cases, ctrlr is statically assigned or dynamically attached by ut_detach_ctrlr(). This might be a little confusing. Hence by adding a flag, attached, to ctrlr, merge ut_detach_ctrlr() into spdk_nvme_detach(), and remove ut_detach_ctrlr() calls. Besides, change one SPDK_CU_ASSERT_FATAL to return NULL because the other cases do that and the callers for ut_attach_ctrlr() already have SPDK_CU_ASSERT_FATAL. Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I2a73f57c6031819d3ae441a6874127ff5d53fc04 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7311 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> |
||
---|---|---|
.. | ||
bdev_zone.c | ||
bdev.c | ||
compress.c | ||
crypto.c | ||
gpt | ||
mt | ||
nvme | ||
part.c | ||
pmem | ||
raid | ||
scsi_nvme.c | ||
vbdev_lvol.c | ||
vbdev_zone_block.c | ||
Makefile |