Commit d48f92cd authored by Keith Busch's avatar Keith Busch Committed by Christoph Hellwig

nvme-tcp: pair send_mutex init with destroy

Each mutex_init() should have a corresponding mutex_destroy().
Signed-off-by: default avatarKeith Busch <kbusch@kernel.org>
Reviewed-by: default avatarSagi Grimberg <sagi@grimberg.me>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent a5df5e79
......@@ -1220,6 +1220,7 @@ static void nvme_tcp_free_queue(struct nvme_ctrl *nctrl, int qid)
sock_release(queue->sock);
kfree(queue->pdu);
mutex_destroy(&queue->send_mutex);
mutex_destroy(&queue->queue_lock);
}
......@@ -1525,6 +1526,7 @@ static int nvme_tcp_alloc_queue(struct nvme_ctrl *nctrl,
sock_release(queue->sock);
queue->sock = NULL;
err_destroy_mutex:
mutex_destroy(&queue->send_mutex);
mutex_destroy(&queue->queue_lock);
return ret;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment