nvmf/fc/ut: Call spdk_nvmf_tgt_destroy() in the correct thread context
Use the same thread context to call both spdk_nvmf_tgt_create() and spdk_nvmf_tgt_destroy(). This is required to ensure the accept poller is registered and unregistered in the same thread context. Signed-off-by: Anil Veerabhadrappa <anil.veerabhadrappa@broadcom.com> Change-Id: I0637c7896ca7504412fbe673355f6904dd81a961 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4449 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
084a062e81
commit
2fc3ef3231
@ -451,7 +451,6 @@ destroy_transport_test(void)
|
||||
{
|
||||
unsigned i;
|
||||
|
||||
set_thread(0);
|
||||
SPDK_CU_ASSERT_FATAL(g_nvmf_tprt != NULL);
|
||||
|
||||
for (i = 0; i < MAX_FC_UT_POLL_THREADS; i++) {
|
||||
@ -460,6 +459,7 @@ destroy_transport_test(void)
|
||||
poll_thread(0);
|
||||
}
|
||||
|
||||
set_thread(0);
|
||||
SPDK_CU_ASSERT_FATAL(g_nvmf_tgt != NULL);
|
||||
g_lld_fini_called = false;
|
||||
spdk_nvmf_tgt_destroy(g_nvmf_tgt, NULL, NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user