diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2015-01-21 11:03:44 -0500 |
---|---|---|
committer | Anna Schumaker <Anna.Schumaker@Netapp.com> | 2015-01-30 10:47:48 -0500 |
commit | ac920d04a7f307bfd7633f60abe33fb626f6ec83 (patch) | |
tree | 6cc09b1f6f088da7736517e8d3781491eaea6b0c /net/sunrpc | |
parent | ce1ab9ab47973dcff7548abda20e49add2c4ca95 (diff) |
xprtrdma: Simplify synopsis of rpcrdma_buffer_create()
Clean up: There is one call site for rpcrdma_buffer_create(). All of
the arguments there are fields of an rpcrdma_xprt.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'net/sunrpc')
-rw-r--r-- | net/sunrpc/xprtrdma/transport.c | 3 | ||||
-rw-r--r-- | net/sunrpc/xprtrdma/verbs.c | 7 | ||||
-rw-r--r-- | net/sunrpc/xprtrdma/xprt_rdma.h | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/net/sunrpc/xprtrdma/transport.c b/net/sunrpc/xprtrdma/transport.c index a487bde71b4a..808b3c52427a 100644 --- a/net/sunrpc/xprtrdma/transport.c +++ b/net/sunrpc/xprtrdma/transport.c | |||
@@ -364,8 +364,7 @@ xprt_setup_rdma(struct xprt_create *args) | |||
364 | * any inline data. Also specify any padding which will be provided | 364 | * any inline data. Also specify any padding which will be provided |
365 | * from a preregistered zero buffer. | 365 | * from a preregistered zero buffer. |
366 | */ | 366 | */ |
367 | rc = rpcrdma_buffer_create(&new_xprt->rx_buf, new_ep, &new_xprt->rx_ia, | 367 | rc = rpcrdma_buffer_create(new_xprt); |
368 | &new_xprt->rx_data); | ||
369 | if (rc) | 368 | if (rc) |
370 | goto out3; | 369 | goto out3; |
371 | 370 | ||
diff --git a/net/sunrpc/xprtrdma/verbs.c b/net/sunrpc/xprtrdma/verbs.c index 958b372cb919..fd71501403fd 100644 --- a/net/sunrpc/xprtrdma/verbs.c +++ b/net/sunrpc/xprtrdma/verbs.c | |||
@@ -1161,9 +1161,11 @@ out_free: | |||
1161 | } | 1161 | } |
1162 | 1162 | ||
1163 | int | 1163 | int |
1164 | rpcrdma_buffer_create(struct rpcrdma_buffer *buf, struct rpcrdma_ep *ep, | 1164 | rpcrdma_buffer_create(struct rpcrdma_xprt *r_xprt) |
1165 | struct rpcrdma_ia *ia, struct rpcrdma_create_data_internal *cdata) | ||
1166 | { | 1165 | { |
1166 | struct rpcrdma_buffer *buf = &r_xprt->rx_buf; | ||
1167 | struct rpcrdma_ia *ia = &r_xprt->rx_ia; | ||
1168 | struct rpcrdma_create_data_internal *cdata = &r_xprt->rx_data; | ||
1167 | char *p; | 1169 | char *p; |
1168 | size_t len, rlen, wlen; | 1170 | size_t len, rlen, wlen; |
1169 | int i, rc; | 1171 | int i, rc; |
@@ -1200,6 +1202,7 @@ rpcrdma_buffer_create(struct rpcrdma_buffer *buf, struct rpcrdma_ep *ep, | |||
1200 | * Register the zeroed pad buffer, if any. | 1202 | * Register the zeroed pad buffer, if any. |
1201 | */ | 1203 | */ |
1202 | if (cdata->padding) { | 1204 | if (cdata->padding) { |
1205 | struct rpcrdma_ep *ep = &r_xprt->rx_ep; | ||
1203 | rc = rpcrdma_register_internal(ia, p, cdata->padding, | 1206 | rc = rpcrdma_register_internal(ia, p, cdata->padding, |
1204 | &ep->rep_pad_mr, &ep->rep_pad); | 1207 | &ep->rep_pad_mr, &ep->rep_pad); |
1205 | if (rc) | 1208 | if (rc) |
diff --git a/net/sunrpc/xprtrdma/xprt_rdma.h b/net/sunrpc/xprtrdma/xprt_rdma.h index 2b4e7787734d..5c2fac3f30b6 100644 --- a/net/sunrpc/xprtrdma/xprt_rdma.h +++ b/net/sunrpc/xprtrdma/xprt_rdma.h | |||
@@ -354,9 +354,7 @@ int rpcrdma_ep_post_recv(struct rpcrdma_ia *, struct rpcrdma_ep *, | |||
354 | /* | 354 | /* |
355 | * Buffer calls - xprtrdma/verbs.c | 355 | * Buffer calls - xprtrdma/verbs.c |
356 | */ | 356 | */ |
357 | int rpcrdma_buffer_create(struct rpcrdma_buffer *, struct rpcrdma_ep *, | 357 | int rpcrdma_buffer_create(struct rpcrdma_xprt *); |
358 | struct rpcrdma_ia *, | ||
359 | struct rpcrdma_create_data_internal *); | ||
360 | void rpcrdma_buffer_destroy(struct rpcrdma_buffer *); | 358 | void rpcrdma_buffer_destroy(struct rpcrdma_buffer *); |
361 | 359 | ||
362 | struct rpcrdma_req *rpcrdma_buffer_get(struct rpcrdma_buffer *); | 360 | struct rpcrdma_req *rpcrdma_buffer_get(struct rpcrdma_buffer *); |