aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/sunrpc/rpcb_clnt.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/net/sunrpc/rpcb_clnt.c b/net/sunrpc/rpcb_clnt.c
index 371d2298c9fc..0d76c0f09bb8 100644
--- a/net/sunrpc/rpcb_clnt.c
+++ b/net/sunrpc/rpcb_clnt.c
@@ -344,11 +344,12 @@ out:
344 return result; 344 return result;
345} 345}
346 346
347static struct rpc_clnt *rpcb_create(char *hostname, struct sockaddr *srvaddr, 347static struct rpc_clnt *rpcb_create(struct net *net, char *hostname,
348 size_t salen, int proto, u32 version) 348 struct sockaddr *srvaddr, size_t salen,
349 int proto, u32 version)
349{ 350{
350 struct rpc_create_args args = { 351 struct rpc_create_args args = {
351 .net = &init_net, 352 .net = net,
352 .protocol = proto, 353 .protocol = proto,
353 .address = srvaddr, 354 .address = srvaddr,
354 .addrsize = salen, 355 .addrsize = salen,
@@ -708,8 +709,8 @@ void rpcb_getport_async(struct rpc_task *task)
708 dprintk("RPC: %5u %s: trying rpcbind version %u\n", 709 dprintk("RPC: %5u %s: trying rpcbind version %u\n",
709 task->tk_pid, __func__, bind_version); 710 task->tk_pid, __func__, bind_version);
710 711
711 rpcb_clnt = rpcb_create(clnt->cl_server, sap, salen, xprt->prot, 712 rpcb_clnt = rpcb_create(xprt->xprt_net, clnt->cl_server, sap, salen,
712 bind_version); 713 xprt->prot, bind_version);
713 if (IS_ERR(rpcb_clnt)) { 714 if (IS_ERR(rpcb_clnt)) {
714 status = PTR_ERR(rpcb_clnt); 715 status = PTR_ERR(rpcb_clnt);
715 dprintk("RPC: %5u %s: rpcb_create failed, error %ld\n", 716 dprintk("RPC: %5u %s: rpcb_create failed, error %ld\n",