diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2014-07-29 17:25:55 -0400 |
---|---|---|
committer | Anna Schumaker <Anna.Schumaker@Netapp.com> | 2014-07-31 16:22:58 -0400 |
commit | 282191cb725db9a1aa80269e8369b06e9270a948 (patch) | |
tree | 09038ff1073a9b121025dbc66d7e25e619042e21 /net | |
parent | bb96193d9104613cd87fb518f25db3fadc36432e (diff) |
xprtrdma: Make rpcrdma_ep_disconnect() return void
Clean up: The return code is used only for dprintk's that are
already redundant.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Tested-by: Steve Wise <swise@opengridcomputing.com>
Tested-by: Shirley Ma <shirley.ma@oracle.com>
Tested-by: Devesh Sharma <devesh.sharma@emulex.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'net')
-rw-r--r-- | net/sunrpc/xprtrdma/transport.c | 2 | ||||
-rw-r--r-- | net/sunrpc/xprtrdma/verbs.c | 14 | ||||
-rw-r--r-- | net/sunrpc/xprtrdma/xprt_rdma.h | 2 |
3 files changed, 6 insertions, 12 deletions
diff --git a/net/sunrpc/xprtrdma/transport.c b/net/sunrpc/xprtrdma/transport.c index f6d280b31dc9..2faac4940563 100644 --- a/net/sunrpc/xprtrdma/transport.c +++ b/net/sunrpc/xprtrdma/transport.c | |||
@@ -414,7 +414,7 @@ xprt_rdma_close(struct rpc_xprt *xprt) | |||
414 | if (r_xprt->rx_ep.rep_connected > 0) | 414 | if (r_xprt->rx_ep.rep_connected > 0) |
415 | xprt->reestablish_timeout = 0; | 415 | xprt->reestablish_timeout = 0; |
416 | xprt_disconnect_done(xprt); | 416 | xprt_disconnect_done(xprt); |
417 | (void) rpcrdma_ep_disconnect(&r_xprt->rx_ep, &r_xprt->rx_ia); | 417 | rpcrdma_ep_disconnect(&r_xprt->rx_ep, &r_xprt->rx_ia); |
418 | } | 418 | } |
419 | 419 | ||
420 | static void | 420 | static void |
diff --git a/net/sunrpc/xprtrdma/verbs.c b/net/sunrpc/xprtrdma/verbs.c index f124f04e2e4e..1208ab2e655f 100644 --- a/net/sunrpc/xprtrdma/verbs.c +++ b/net/sunrpc/xprtrdma/verbs.c | |||
@@ -830,10 +830,7 @@ rpcrdma_ep_destroy(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia) | |||
830 | cancel_delayed_work_sync(&ep->rep_connect_worker); | 830 | cancel_delayed_work_sync(&ep->rep_connect_worker); |
831 | 831 | ||
832 | if (ia->ri_id->qp) { | 832 | if (ia->ri_id->qp) { |
833 | rc = rpcrdma_ep_disconnect(ep, ia); | 833 | rpcrdma_ep_disconnect(ep, ia); |
834 | if (rc) | ||
835 | dprintk("RPC: %s: rpcrdma_ep_disconnect" | ||
836 | " returned %i\n", __func__, rc); | ||
837 | rdma_destroy_qp(ia->ri_id); | 834 | rdma_destroy_qp(ia->ri_id); |
838 | ia->ri_id->qp = NULL; | 835 | ia->ri_id->qp = NULL; |
839 | } | 836 | } |
@@ -871,10 +868,8 @@ rpcrdma_ep_connect(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia) | |||
871 | struct rpcrdma_xprt *xprt; | 868 | struct rpcrdma_xprt *xprt; |
872 | retry: | 869 | retry: |
873 | dprintk("RPC: %s: reconnecting...\n", __func__); | 870 | dprintk("RPC: %s: reconnecting...\n", __func__); |
874 | rc = rpcrdma_ep_disconnect(ep, ia); | 871 | |
875 | if (rc && rc != -ENOTCONN) | 872 | rpcrdma_ep_disconnect(ep, ia); |
876 | dprintk("RPC: %s: rpcrdma_ep_disconnect" | ||
877 | " status %i\n", __func__, rc); | ||
878 | rpcrdma_flush_cqs(ep); | 873 | rpcrdma_flush_cqs(ep); |
879 | 874 | ||
880 | if (ia->ri_memreg_strategy == RPCRDMA_FRMR) | 875 | if (ia->ri_memreg_strategy == RPCRDMA_FRMR) |
@@ -984,7 +979,7 @@ out: | |||
984 | * This call is not reentrant, and must not be made in parallel | 979 | * This call is not reentrant, and must not be made in parallel |
985 | * on the same endpoint. | 980 | * on the same endpoint. |
986 | */ | 981 | */ |
987 | int | 982 | void |
988 | rpcrdma_ep_disconnect(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia) | 983 | rpcrdma_ep_disconnect(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia) |
989 | { | 984 | { |
990 | int rc; | 985 | int rc; |
@@ -1001,7 +996,6 @@ rpcrdma_ep_disconnect(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia) | |||
1001 | dprintk("RPC: %s: rdma_disconnect %i\n", __func__, rc); | 996 | dprintk("RPC: %s: rdma_disconnect %i\n", __func__, rc); |
1002 | ep->rep_connected = rc; | 997 | ep->rep_connected = rc; |
1003 | } | 998 | } |
1004 | return rc; | ||
1005 | } | 999 | } |
1006 | 1000 | ||
1007 | static int | 1001 | static int |
diff --git a/net/sunrpc/xprtrdma/xprt_rdma.h b/net/sunrpc/xprtrdma/xprt_rdma.h index 1ee6db30abc5..c419498b8f46 100644 --- a/net/sunrpc/xprtrdma/xprt_rdma.h +++ b/net/sunrpc/xprtrdma/xprt_rdma.h | |||
@@ -341,7 +341,7 @@ int rpcrdma_ep_create(struct rpcrdma_ep *, struct rpcrdma_ia *, | |||
341 | struct rpcrdma_create_data_internal *); | 341 | struct rpcrdma_create_data_internal *); |
342 | void rpcrdma_ep_destroy(struct rpcrdma_ep *, struct rpcrdma_ia *); | 342 | void rpcrdma_ep_destroy(struct rpcrdma_ep *, struct rpcrdma_ia *); |
343 | int rpcrdma_ep_connect(struct rpcrdma_ep *, struct rpcrdma_ia *); | 343 | int rpcrdma_ep_connect(struct rpcrdma_ep *, struct rpcrdma_ia *); |
344 | int rpcrdma_ep_disconnect(struct rpcrdma_ep *, struct rpcrdma_ia *); | 344 | void rpcrdma_ep_disconnect(struct rpcrdma_ep *, struct rpcrdma_ia *); |
345 | 345 | ||
346 | int rpcrdma_ep_post(struct rpcrdma_ia *, struct rpcrdma_ep *, | 346 | int rpcrdma_ep_post(struct rpcrdma_ia *, struct rpcrdma_ep *, |
347 | struct rpcrdma_req *); | 347 | struct rpcrdma_req *); |