summaryrefslogtreecommitdiffstats
path: root/drivers/nvme
diff options
context:
space:
mode:
authorChunguang.xu <chunguang.xu@shopee.com>2024-12-03 04:34:40 +0100
committerKeith Busch <kbusch@kernel.org>2024-12-04 19:15:46 +0100
commitfec55c29e54d3ca6fe9d7d7d9266098b4514fd34 (patch)
treeffadd9dbde8fa9360df7b065ef1209dcdb1ba7ff /drivers/nvme
parentnvme-pci: don't use dma_alloc_noncontiguous with 0 merge boundary (diff)
downloadlinux-fec55c29e54d3ca6fe9d7d7d9266098b4514fd34.tar.xz
linux-fec55c29e54d3ca6fe9d7d7d9266098b4514fd34.zip
nvme-tcp: fix the memleak while create new ctrl failed
Now while we create new ctrl failed, we have not free the tagset occupied by admin_q, here try to fix it. Fixes: fd1418de10b9 ("nvme-tcp: avoid open-coding nvme_tcp_teardown_admin_queue()") Signed-off-by: Chunguang.xu <chunguang.xu@shopee.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Keith Busch <kbusch@kernel.org>
Diffstat (limited to 'drivers/nvme')
-rw-r--r--drivers/nvme/host/tcp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index 3e416af2659f..55abfe5e1d25 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -2278,7 +2278,7 @@ destroy_io:
}
destroy_admin:
nvme_stop_keep_alive(ctrl);
- nvme_tcp_teardown_admin_queue(ctrl, false);
+ nvme_tcp_teardown_admin_queue(ctrl, new);
return ret;
}