summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorzhong jiang <zhongjiang@huawei.com>2018-08-07 14:20:00 +0300
committerJ. Bruce Fields <bfields@redhat.com>2018-08-09 23:11:21 +0300
commitac5bb5b3b0502b90b489e6b19c46b8c3dbe2e640 (patch)
tree0840680e1e2ae1cb222fb982369e792b20d659d3 /net
parenta677a78325b3057ce03b6129f549ece85b0c8dd2 (diff)
downloadlinux-ac5bb5b3b0502b90b489e6b19c46b8c3dbe2e640.tar.xz
rpc: remove unneeded variable 'ret' in rdma_listen_handler
The ret is not modified after initalization, So just remove the variable and return 0. Signed-off-by: zhong jiang <zhongjiang@huawei.com> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/xprtrdma/svc_rdma_transport.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtrdma/svc_rdma_transport.c
index e9535a66bab0..2317cf79a1ed 100644
--- a/net/sunrpc/xprtrdma/svc_rdma_transport.c
+++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c
@@ -296,7 +296,6 @@ static int rdma_listen_handler(struct rdma_cm_id *cma_id,
struct rdma_cm_event *event)
{
struct sockaddr *sap = (struct sockaddr *)&cma_id->route.addr.src_addr;
- int ret = 0;
trace_svcrdma_cm_event(event, sap);
@@ -315,7 +314,7 @@ static int rdma_listen_handler(struct rdma_cm_id *cma_id,
break;
}
- return ret;
+ return 0;
}
static int rdma_cma_handler(struct rdma_cm_id *cma_id,