From 039c8341e37f9e92da91f9669d931f049bb1cc19 Mon Sep 17 00:00:00 2001 From: Ben Walker Date: Mon, 22 Oct 2018 14:41:03 -0700 Subject: [PATCH] nvmf/rdma: Remove handling for LAST_WQE_REACHED This event only occurs when using shared receive queues, which the target does not currently support. Change-Id: If155843610cf0e961b9783d4afd64b969b4316f4 Signed-off-by: Ben Walker Reviewed-on: https://review.gerrithub.io/430388 Tested-by: SPDK CI Jenkins Chandler-Test-Pool: SPDK Automated Test System Reviewed-by: Sasha Kotchubievsky Reviewed-by: Changpeng Liu Reviewed-by: Shuhei Matsumoto Reviewed-by: Jim Harris --- lib/nvmf/rdma.c | 32 +------------------------------- 1 file changed, 1 insertion(+), 31 deletions(-) diff --git a/lib/nvmf/rdma.c b/lib/nvmf/rdma.c index 333e703f51..61f0deca9e 100644 --- a/lib/nvmf/rdma.c +++ b/lib/nvmf/rdma.c @@ -2269,31 +2269,6 @@ _spdk_nvmf_rdma_qp_error(void *arg) spdk_nvmf_rdma_qpair_recover(rqpair); } -static void -_spdk_nvmf_rdma_qp_last_wqe(void *arg) -{ - struct spdk_nvmf_rdma_qpair *rqpair = arg; - enum ibv_qp_state state; - - spdk_nvmf_rdma_qpair_dec_refcnt(rqpair); - - state = rqpair->ibv_attr.qp_state; - if (state != IBV_QPS_ERR) { - /* Error was already recovered */ - return; - } - - /* Clear out the states that are safe to clear any time, plus the - * RDMA data transfer states. */ - _spdk_nvmf_rdma_qp_cleanup_safe_states(rqpair); - - spdk_nvmf_rdma_drain_state_queue(rqpair, RDMA_REQUEST_STATE_TRANSFERRING_HOST_TO_CONTROLLER); - spdk_nvmf_rdma_drain_state_queue(rqpair, RDMA_REQUEST_STATE_TRANSFERRING_CONTROLLER_TO_HOST); - spdk_nvmf_rdma_drain_state_queue(rqpair, RDMA_REQUEST_STATE_COMPLETING); - - spdk_nvmf_rdma_qpair_recover(rqpair); -} - static void spdk_nvmf_process_ib_event(struct spdk_nvmf_rdma_device *device) { @@ -2323,12 +2298,7 @@ spdk_nvmf_process_ib_event(struct spdk_nvmf_rdma_device *device) spdk_thread_send_msg(rqpair->qpair.group->thread, _spdk_nvmf_rdma_qp_error, rqpair); break; case IBV_EVENT_QP_LAST_WQE_REACHED: - rqpair = event.element.qp->qp_context; - spdk_trace_record(TRACE_RDMA_IBV_ASYNC_EVENT, 0, 0, - (uintptr_t)rqpair->cm_id, event.event_type); - spdk_nvmf_rdma_update_ibv_state(rqpair); - spdk_nvmf_rdma_qpair_inc_refcnt(rqpair); - spdk_thread_send_msg(rqpair->qpair.group->thread, _spdk_nvmf_rdma_qp_last_wqe, rqpair); + /* This event only occurs for shared receive queues, which are not currently supported. */ break; case IBV_EVENT_SQ_DRAINED: /* This event occurs frequently in both error and non-error states.