summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorSagi Grimberg <sagi@grimberg.me>2017-11-13 23:29:05 +0200
committerChristoph Hellwig <hch@lst.de>2018-01-08 11:01:51 +0100
commitcb4876e8ce1c6d78306c206df1970748ebb89025 (patch)
treeab70a819ce04b052c12f61b4e3917abda28ac6aa /drivers
parentfb350e0ad99359768e1e80b4784692031ec340e4 (diff)
downloadlinux-stable-cb4876e8ce1c6d78306c206df1970748ebb89025.tar.gz
linux-stable-cb4876e8ce1c6d78306c206df1970748ebb89025.tar.bz2
linux-stable-cb4876e8ce1c6d78306c206df1970748ebb89025.zip
nvmet-rdma: removed queue cleanup from module exit
We already do that when we are notified in device removal which is triggered when unregistering as an ib client. Signed-off-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Max Gurtovoy <maxg@mellanox.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/nvme/target/rdma.c18
1 files changed, 1 insertions, 17 deletions
diff --git a/drivers/nvme/target/rdma.c b/drivers/nvme/target/rdma.c
index 0e4c15754c58..454a5dce81f8 100644
--- a/drivers/nvme/target/rdma.c
+++ b/drivers/nvme/target/rdma.c
@@ -1503,25 +1503,9 @@ err_ib_client:
static void __exit nvmet_rdma_exit(void)
{
- struct nvmet_rdma_queue *queue;
-
nvmet_unregister_transport(&nvmet_rdma_ops);
-
- flush_scheduled_work();
-
- mutex_lock(&nvmet_rdma_queue_mutex);
- while ((queue = list_first_entry_or_null(&nvmet_rdma_queue_list,
- struct nvmet_rdma_queue, queue_list))) {
- list_del_init(&queue->queue_list);
-
- mutex_unlock(&nvmet_rdma_queue_mutex);
- __nvmet_rdma_queue_disconnect(queue);
- mutex_lock(&nvmet_rdma_queue_mutex);
- }
- mutex_unlock(&nvmet_rdma_queue_mutex);
-
- flush_scheduled_work();
ib_unregister_client(&nvmet_rdma_ib_client);
+ WARN_ON_ONCE(!list_empty(&nvmet_rdma_queue_list));
ida_destroy(&nvmet_rdma_queue_ida);
}