nvme/rdma: Don't log error for WC Flush Error
This type of errors is not fatal and can be observed when qpairs are diconnected. The same approach is used in target side. Change-Id: Ic3c7b1731c0cbd2e98d776f0f0c5d82464b3d556 Signed-off-by: Alexey Marchuk <alexeymar@mellanox.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9416 Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
8106e20726
commit
abc45c4642
@ -2165,6 +2165,24 @@ nvme_rdma_conditional_fail_qpair(struct nvme_rdma_qpair *rqpair, struct nvme_rdm
|
||||
nvme_rdma_fail_qpair(&rqpair->qpair, 0);
|
||||
}
|
||||
|
||||
static inline void
|
||||
nvme_rdma_log_wc_status(struct nvme_rdma_qpair *rqpair, struct ibv_wc *wc)
|
||||
{
|
||||
struct nvme_rdma_wr *rdma_wr = (struct nvme_rdma_wr *)wc->wr_id;
|
||||
|
||||
if (wc->status == IBV_WC_WR_FLUSH_ERR) {
|
||||
/* If qpair is in ERR state, we will receive completions for all posted and not completed
|
||||
* Work Requests with IBV_WC_WR_FLUSH_ERR status. Don't log an error in that case */
|
||||
SPDK_DEBUGLOG(nvme, "WC error, qid %u, qp state %d, request 0x%lu type %d, status: (%d): %s\n",
|
||||
rqpair->qpair.id, rqpair->qpair.state, wc->wr_id, rdma_wr->type, wc->status,
|
||||
ibv_wc_status_str(wc->status));
|
||||
} else {
|
||||
SPDK_ERRLOG("WC error, qid %u, qp state %d, request 0x%lu type %d, status: (%d): %s\n",
|
||||
rqpair->qpair.id, rqpair->qpair.state, wc->wr_id, rdma_wr->type, wc->status,
|
||||
ibv_wc_status_str(wc->status));
|
||||
}
|
||||
}
|
||||
|
||||
static int
|
||||
nvme_rdma_cq_process_completions(struct ibv_cq *cq, uint32_t batch_size,
|
||||
struct nvme_rdma_poll_group *group,
|
||||
@ -2199,8 +2217,7 @@ nvme_rdma_cq_process_completions(struct ibv_cq *cq, uint32_t batch_size,
|
||||
rqpair->current_num_recvs--;
|
||||
|
||||
if (wc[i].status) {
|
||||
SPDK_ERRLOG("CQ error on Queue Pair %p, Response Index %lu (%d): %s\n",
|
||||
rqpair, wc[i].wr_id, wc[i].status, ibv_wc_status_str(wc[i].status));
|
||||
nvme_rdma_log_wc_status(rqpair, &wc[i]);
|
||||
nvme_rdma_conditional_fail_qpair(rqpair, group);
|
||||
completion_rc = -ENXIO;
|
||||
continue;
|
||||
@ -2251,9 +2268,8 @@ nvme_rdma_cq_process_completions(struct ibv_cq *cq, uint32_t batch_size,
|
||||
}
|
||||
assert(rqpair->current_num_sends > 0);
|
||||
rqpair->current_num_sends--;
|
||||
nvme_rdma_log_wc_status(rqpair, &wc[i]);
|
||||
nvme_rdma_conditional_fail_qpair(rqpair, group);
|
||||
SPDK_ERRLOG("CQ error on Queue Pair %p, Response Index %lu (%d): %s\n",
|
||||
rqpair, wc[i].wr_id, wc[i].status, ibv_wc_status_str(wc[i].status));
|
||||
completion_rc = -ENXIO;
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user