nvme: free associated memory when deleting the IO queue pair
Change-Id: Ibc139c5fd2e0ef72b6dbd5a8416aec916759430f Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
This commit is contained in:
parent
2bfb991e42
commit
277ca8ddd0
@ -1190,8 +1190,6 @@ nvme_ctrlr_destruct(struct spdk_nvme_ctrlr *ctrlr)
|
||||
while (!TAILQ_EMPTY(&ctrlr->active_io_qpairs)) {
|
||||
struct spdk_nvme_qpair *qpair = TAILQ_FIRST(&ctrlr->active_io_qpairs);
|
||||
|
||||
nvme_qpair_destroy(qpair);
|
||||
|
||||
spdk_nvme_ctrlr_free_io_qpair(qpair);
|
||||
}
|
||||
|
||||
|
@ -1265,6 +1265,7 @@ nvme_pcie_ctrlr_delete_io_qpair(struct spdk_nvme_ctrlr *ctrlr, struct spdk_nvme_
|
||||
return -1;
|
||||
}
|
||||
|
||||
nvme_qpair_destroy(qpair);
|
||||
spdk_free(pqpair);
|
||||
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user