nvmf/rdma: Delay updating rdma qpair state until fully initialized

The state of the RDMA qpair is not entirely initialized (RTS)
until after the CM event is accepted. Delay caching the state
until then.

Change-Id: I39befb867fc6a01e94d7fc176071aaabb906bd07
Signed-off-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-on: https://review.gerrithub.io/421041
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
This commit is contained in:
Ben Walker 2018-08-01 16:00:33 -07:00 committed by Jim Harris
parent a9b9f0952d
commit d0d3dc4e8b

View File

@ -675,8 +675,6 @@ spdk_nvmf_rdma_qpair_initialize(struct spdk_nvmf_qpair *qpair)
rqpair->state_cntr[rdma_req->state]++;
}
spdk_nvmf_rdma_get_ibv_state(rqpair);
return 0;
}
@ -2303,6 +2301,8 @@ spdk_nvmf_rdma_poll_group_add(struct spdk_nvmf_transport_poll_group *group,
return -1;
}
spdk_nvmf_rdma_get_ibv_state(rqpair);
return 0;
}