Spdk/lib/bdev
Darek Stojaczyk f93b6fb0a4 bdev: defer unregister untill *all* descriptors are closed
We used to wait only for those descriptors which
specified the hotremove notification callback. The
bdev could've been removed before the descriptor
was closed and the subsequent spdk_bdev_close would
simply segfault.

This patch modifies spdk_bdev_unregister to always
wait for all descriptors to be closed before actually
unregistering the bdev. This consolidates the bdev
unregister behavior for descriptors with and without
the hotremove callback.

Change-Id: I9b358209c6abd301b6fe8660e27bc6fa4ef485d6
Signed-off-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/450175
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-04-23 17:06:37 +00:00
..
aio bdev/aio: cleanup bdev_aio.h 2019-03-01 13:03:55 +00:00
compress bdev: deprecate spdk_vbdev_register 2019-04-04 08:28:31 +00:00
crypto crypto: switch to spdk_*malloc(). 2019-04-04 20:59:36 +00:00
error bdev: make spdk_bdev_register_module_xxx function names predictable 2019-02-11 23:56:53 +00:00
gpt bdev: switch to spdk_*malloc(). 2019-04-09 06:30:42 +00:00
iscsi bdev/iscsi: fix iscsi bdev wrong lun id 2019-04-01 01:16:51 +00:00
lvol bdev: deprecate spdk_vbdev_register 2019-04-04 08:28:31 +00:00
malloc bdev/malloc: allocate bdev struct using regular calloc 2019-04-09 06:30:42 +00:00
null bdev/null: allocate bdev struct using regular calloc 2019-03-20 11:12:59 +00:00
nvme bdev/nvme: fix issue about coredump which caused by assert error. 2019-04-22 15:23:11 +00:00
ocf ocf: update try-locks in env 2019-04-19 13:05:35 +00:00
passthru bdev: deprecate spdk_vbdev_register 2019-04-04 08:28:31 +00:00
pmem bdev: process failure of spdk_bdev_io_get_buf_cb in each bdev module 2019-02-27 07:28:15 +00:00
raid bdev/raid: Add callback parameters to remove_base_devices() 2019-04-10 20:41:57 +00:00
rbd bdev: process failure of spdk_bdev_io_get_buf_cb in each bdev module 2019-02-27 07:28:15 +00:00
rpc bdev: remove delete_bdev RPC 2019-03-01 08:50:07 +00:00
split bdev: make spdk_bdev_register_module_xxx function names predictable 2019-02-11 23:56:53 +00:00
uring bdev: Add io_uring bdev module 2019-03-22 18:51:48 +00:00
virtio virtio: switch to spdk_*malloc(). 2019-03-28 07:39:31 +00:00
bdev.c bdev: defer unregister untill *all* descriptors are closed 2019-04-23 17:06:37 +00:00
Makefile bdev/compress: add compression vbdev module 2019-03-27 14:51:22 +00:00
part.c bdev: deprecate spdk_vbdev_register 2019-04-04 08:28:31 +00:00
scsi_nvme.c bdev: move error union to internal spdk_bdev_io struct 2018-06-26 20:04:07 +00:00
vtune.c mk: don't use '-include spdk/config.h' 2018-10-02 23:13:32 +00:00