From: Bryan Schumaker Date: Tue, 27 Mar 2012 17:46:32 +0000 (-0400) Subject: SUNRPC: Use the already looked-up xprt in rpcb_getport_async() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=864cf9bf99f62d2095c8e6cc3a87af80b263984e;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git SUNRPC: Use the already looked-up xprt in rpcb_getport_async() rbcb_getport_async() was looking up the rpc_xprt (reference++) and then later looking it up again (reference++) to pass through the rpcbind_args. The xprt would only be dereferenced once, when we were done with the rpcbind_args (reference--). This leaves an extra reference to the transport that would never go away. Signed-off-by: Bryan Schumaker Signed-off-by: Trond Myklebust --- diff --git a/net/sunrpc/rpcb_clnt.c b/net/sunrpc/rpcb_clnt.c index 207a74696c9f..78ac39fd9fe7 100644 --- a/net/sunrpc/rpcb_clnt.c +++ b/net/sunrpc/rpcb_clnt.c @@ -734,7 +734,7 @@ void rpcb_getport_async(struct rpc_task *task) map->r_vers = clnt->cl_vers; map->r_prot = xprt->prot; map->r_port = 0; - map->r_xprt = xprt_get(xprt); + map->r_xprt = xprt; map->r_status = -EIO; switch (bind_version) {