ib_srpt: Unload properly with RDMA/CM disabled

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@5474 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2014-04-24 18:43:41 +00:00
parent 99b7abe259
commit 6cbe580d89

View File

@@ -4378,7 +4378,8 @@ static void __exit srpt_cleanup_module(void)
{
TRACE_ENTRY();
rdma_destroy_id(rdma_cm_id);
if (rdma_cm_id)
rdma_destroy_id(rdma_cm_id);
ib_unregister_client(&srpt_client);
#ifdef CONFIG_SCST_PROC
srpt_unregister_procfs_entry(&srpt_template);