diff --git a/lib/nvme/nvme_rdma.c b/lib/nvme/nvme_rdma.c index cbadd4170..968401d39 100644 --- a/lib/nvme/nvme_rdma.c +++ b/lib/nvme/nvme_rdma.c @@ -2435,13 +2435,6 @@ nvme_rdma_log_wc_status(struct nvme_rdma_qpair *rqpair, struct ibv_wc *wc) } } -static inline bool -nvme_rdma_is_rxe_device(struct ibv_device_attr *dev_attr) -{ - return dev_attr->vendor_id == SPDK_RDMA_RXE_VENDOR_ID_OLD || - dev_attr->vendor_id == SPDK_RDMA_RXE_VENDOR_ID_NEW; -} - static int nvme_rdma_cq_process_completions(struct ibv_cq *cq, uint32_t batch_size, struct nvme_rdma_poller *poller, @@ -2531,25 +2524,10 @@ nvme_rdma_cq_process_completions(struct ibv_cq *cq, uint32_t batch_size, continue; } - if (spdk_unlikely(rdma_req->req == NULL)) { - struct ibv_device_attr dev_attr; - int query_status; - - /* Bug in Soft Roce - we may receive a completion without error status when qpair is disconnected/destroyed. - * As sanity check - log an error if we use a real HW (it should never happen) */ - query_status = ibv_query_device(cq->context, &dev_attr); - if (query_status == 0) { - if (!nvme_rdma_is_rxe_device(&dev_attr)) { - SPDK_ERRLOG("Received malformed completion: request 0x%"PRIx64" type %d\n", wc->wr_id, - rdma_wr->type); - assert(0); - } - } else { - SPDK_ERRLOG("Failed to query ib device\n"); - assert(0); - } - continue; - } + /* We do not support Soft Roce anymore. Other than Soft Roce's bug, we should not + * receive a completion without error status after qpair is disconnected/destroyed. + */ + assert(rdma_req->req != NULL); rqpair = nvme_rdma_qpair(rdma_req->req->qpair); rdma_req->completion_flags |= NVME_RDMA_SEND_COMPLETED;