We should always called the unregister callback on the same thread that spdk_bdev_unregister() was originally called. So save the thread pointer and use an spdk_thread_send_msg() to make sure it gets called on the correct thread when the unregister finishes. Also add unit test that reproduces the original issue. Fixes issue #2883. Signed-off-by: Jim Harris <james.r.harris@intel.com> Change-Id: Ib3d89368aa358bc7a8db46a8a8cb6339340469d9 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/16554 Reviewed-by: Mike Gerdts <mgerdts@nvidia.com> Reviewed-by: Xiaodong Liu <xiaodong.liu@intel.com> Reviewed-by: Shuhei Matsumoto <smatsumoto@nvidia.com> Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com> Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> |
||
---|---|---|
.. | ||
bdev_ut.c | ||
Makefile |