aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2016-09-15 10:56:35 -0400
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2016-09-19 13:08:38 -0400
commitb157380af1941a43f3cfa244db1018f717031a42 (patch)
tree52cddc22561f59c625f96f11d2172d296739b940 /net
parent13650c23f10603154d989cff70b5c8a889e69fc2 (diff)
xprtrdma: Simplify rpcrdma_ep_post_recv()
Clean up. Since commit fc66448549bb ("xprtrdma: Split the completion queue"), rpcrdma_ep_post_recv() no longer uses the "ep" argument. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/xprtrdma/backchannel.c2
-rw-r--r--net/sunrpc/xprtrdma/rpc_rdma.c2
-rw-r--r--net/sunrpc/xprtrdma/verbs.c9
-rw-r--r--net/sunrpc/xprtrdma/xprt_rdma.h3
4 files changed, 5 insertions, 11 deletions
diff --git a/net/sunrpc/xprtrdma/backchannel.c b/net/sunrpc/xprtrdma/backchannel.c
index a19530d56c66..887ef44c1351 100644
--- a/net/sunrpc/xprtrdma/backchannel.c
+++ b/net/sunrpc/xprtrdma/backchannel.c
@@ -397,7 +397,7 @@ out_overflow:
397out_short: 397out_short:
398 pr_warn("RPC/RDMA short backward direction call\n"); 398 pr_warn("RPC/RDMA short backward direction call\n");
399 399
400 if (rpcrdma_ep_post_recv(&r_xprt->rx_ia, &r_xprt->rx_ep, rep)) 400 if (rpcrdma_ep_post_recv(&r_xprt->rx_ia, rep))
401 xprt_disconnect_done(xprt); 401 xprt_disconnect_done(xprt);
402 else 402 else
403 pr_warn("RPC: %s: reposting rep %p\n", 403 pr_warn("RPC: %s: reposting rep %p\n",
diff --git a/net/sunrpc/xprtrdma/rpc_rdma.c b/net/sunrpc/xprtrdma/rpc_rdma.c
index 68a39c004851..6187cee87fa9 100644
--- a/net/sunrpc/xprtrdma/rpc_rdma.c
+++ b/net/sunrpc/xprtrdma/rpc_rdma.c
@@ -1141,6 +1141,6 @@ out_duplicate:
1141 1141
1142repost: 1142repost:
1143 r_xprt->rx_stats.bad_reply_count++; 1143 r_xprt->rx_stats.bad_reply_count++;
1144 if (rpcrdma_ep_post_recv(&r_xprt->rx_ia, &r_xprt->rx_ep, rep)) 1144 if (rpcrdma_ep_post_recv(&r_xprt->rx_ia, rep))
1145 rpcrdma_recv_buffer_put(rep); 1145 rpcrdma_recv_buffer_put(rep);
1146} 1146}
diff --git a/net/sunrpc/xprtrdma/verbs.c b/net/sunrpc/xprtrdma/verbs.c
index 1f7f4a9623de..7b189fe680bb 100644
--- a/net/sunrpc/xprtrdma/verbs.c
+++ b/net/sunrpc/xprtrdma/verbs.c
@@ -1265,7 +1265,7 @@ rpcrdma_ep_post(struct rpcrdma_ia *ia,
1265 int i, rc; 1265 int i, rc;
1266 1266
1267 if (rep) { 1267 if (rep) {
1268 rc = rpcrdma_ep_post_recv(ia, ep, rep); 1268 rc = rpcrdma_ep_post_recv(ia, rep);
1269 if (rc) 1269 if (rc)
1270 return rc; 1270 return rc;
1271 req->rl_reply = NULL; 1271 req->rl_reply = NULL;
@@ -1300,12 +1300,8 @@ out_postsend_err:
1300 return -ENOTCONN; 1300 return -ENOTCONN;
1301} 1301}
1302 1302
1303/*
1304 * (Re)post a receive buffer.
1305 */
1306int 1303int
1307rpcrdma_ep_post_recv(struct rpcrdma_ia *ia, 1304rpcrdma_ep_post_recv(struct rpcrdma_ia *ia,
1308 struct rpcrdma_ep *ep,
1309 struct rpcrdma_rep *rep) 1305 struct rpcrdma_rep *rep)
1310{ 1306{
1311 struct ib_recv_wr recv_wr, *recv_wr_fail; 1307 struct ib_recv_wr recv_wr, *recv_wr_fail;
@@ -1344,7 +1340,6 @@ rpcrdma_ep_post_extra_recv(struct rpcrdma_xprt *r_xprt, unsigned int count)
1344{ 1340{
1345 struct rpcrdma_buffer *buffers = &r_xprt->rx_buf; 1341 struct rpcrdma_buffer *buffers = &r_xprt->rx_buf;
1346 struct rpcrdma_ia *ia = &r_xprt->rx_ia; 1342 struct rpcrdma_ia *ia = &r_xprt->rx_ia;
1347 struct rpcrdma_ep *ep = &r_xprt->rx_ep;
1348 struct rpcrdma_rep *rep; 1343 struct rpcrdma_rep *rep;
1349 int rc; 1344 int rc;
1350 1345
@@ -1355,7 +1350,7 @@ rpcrdma_ep_post_extra_recv(struct rpcrdma_xprt *r_xprt, unsigned int count)
1355 rep = rpcrdma_buffer_get_rep_locked(buffers); 1350 rep = rpcrdma_buffer_get_rep_locked(buffers);
1356 spin_unlock(&buffers->rb_lock); 1351 spin_unlock(&buffers->rb_lock);
1357 1352
1358 rc = rpcrdma_ep_post_recv(ia, ep, rep); 1353 rc = rpcrdma_ep_post_recv(ia, rep);
1359 if (rc) 1354 if (rc)
1360 goto out_rc; 1355 goto out_rc;
1361 } 1356 }
diff --git a/net/sunrpc/xprtrdma/xprt_rdma.h b/net/sunrpc/xprtrdma/xprt_rdma.h
index 4875af772735..decd13417ac2 100644
--- a/net/sunrpc/xprtrdma/xprt_rdma.h
+++ b/net/sunrpc/xprtrdma/xprt_rdma.h
@@ -457,8 +457,7 @@ void rpcrdma_ep_disconnect(struct rpcrdma_ep *, struct rpcrdma_ia *);
457 457
458int rpcrdma_ep_post(struct rpcrdma_ia *, struct rpcrdma_ep *, 458int rpcrdma_ep_post(struct rpcrdma_ia *, struct rpcrdma_ep *,
459 struct rpcrdma_req *); 459 struct rpcrdma_req *);
460int rpcrdma_ep_post_recv(struct rpcrdma_ia *, struct rpcrdma_ep *, 460int rpcrdma_ep_post_recv(struct rpcrdma_ia *, struct rpcrdma_rep *);
461 struct rpcrdma_rep *);
462 461
463/* 462/*
464 * Buffer calls - xprtrdma/verbs.c 463 * Buffer calls - xprtrdma/verbs.c