From: Sean Hefty Date: Wed, 3 Oct 2012 22:05:20 +0000 (-0700) Subject: rping: Reduce retry_count to fit in 3-bits X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=5ed551f9ebc2af74eb2e330b258f0203cbf381e3;p=~shefty%2Flibrdmacm.git rping: Reduce retry_count to fit in 3-bits retry_count is a 3 bit value on IB, reduce it from 10 to 7. A value of 10 prevents rping from working over the Intel IB HCA. Problem reported by Doug Ledford The retry_count is also not set when calling rdma_accept. Rather than passing different values into rdma_accept than what was specified by the remote side, use the values given in the connection request. Signed-off-by: Sean Hefty --- diff --git a/examples/rping.c b/examples/rping.c index 785338e3..32bd70ac 100644 --- a/examples/rping.c +++ b/examples/rping.c @@ -342,16 +342,11 @@ error: static int rping_accept(struct rping_cb *cb) { - struct rdma_conn_param conn_param; int ret; DEBUG_LOG("accepting client connection request\n"); - memset(&conn_param, 0, sizeof conn_param); - conn_param.responder_resources = 1; - conn_param.initiator_depth = 1; - - ret = rdma_accept(cb->child_cm_id, &conn_param); + ret = rdma_accept(cb->child_cm_id, NULL); if (ret) { perror("rdma_accept"); return ret; @@ -975,7 +970,7 @@ static int rping_connect_client(struct rping_cb *cb) memset(&conn_param, 0, sizeof conn_param); conn_param.responder_resources = 1; conn_param.initiator_depth = 1; - conn_param.retry_count = 10; + conn_param.retry_count = 7; ret = rdma_connect(cb->cm_id, &conn_param); if (ret) {