In the Linux kernel, the following vulnerability has been resolved:nvme-rdma: destroy cm id before destroy qp to avoid use after freeWe should always destroy cm_id before destroy qp to avoid to get cmaevent after qp was destroyed, which may lead to use after free.In RDMA connection establishment error flow, don't destroy qp in cmevent handler.Just report cm_error to upper level, qp will be destroyin nvme_rdma_alloc_queue() after destroy cm id.
CWE-416 Use After Free