aboutsummaryrefslogtreecommitdiffstats
path: root/net/sunrpc/rpcb_clnt.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sunrpc/rpcb_clnt.c')
-rw-r--r--net/sunrpc/rpcb_clnt.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/net/sunrpc/rpcb_clnt.c b/net/sunrpc/rpcb_clnt.c
index 41013dd66ac3..03ae007641e4 100644
--- a/net/sunrpc/rpcb_clnt.c
+++ b/net/sunrpc/rpcb_clnt.c
@@ -270,10 +270,9 @@ static int rpcb_register_netid4(struct sockaddr_in *address_to_register,
270 char buf[32]; 270 char buf[32];
271 271
272 /* Construct AF_INET universal address */ 272 /* Construct AF_INET universal address */
273 snprintf(buf, sizeof(buf), 273 snprintf(buf, sizeof(buf), "%pI4.%u.%u",
274 NIPQUAD_FMT".%u.%u", 274 &address_to_register->sin_addr.s_addr,
275 NIPQUAD(address_to_register->sin_addr.s_addr), 275 port >> 8, port & 0xff);
276 port >> 8, port & 0xff);
277 map->r_addr = buf; 276 map->r_addr = buf;
278 277
279 dprintk("RPC: %sregistering [%u, %u, %s, '%s'] with " 278 dprintk("RPC: %sregistering [%u, %u, %s, '%s'] with "
@@ -305,9 +304,9 @@ static int rpcb_register_netid6(struct sockaddr_in6 *address_to_register,
305 snprintf(buf, sizeof(buf), "::.%u.%u", 304 snprintf(buf, sizeof(buf), "::.%u.%u",
306 port >> 8, port & 0xff); 305 port >> 8, port & 0xff);
307 else 306 else
308 snprintf(buf, sizeof(buf), NIP6_FMT".%u.%u", 307 snprintf(buf, sizeof(buf), "%pI6.%u.%u",
309 NIP6(address_to_register->sin6_addr), 308 &address_to_register->sin6_addr,
310 port >> 8, port & 0xff); 309 port >> 8, port & 0xff);
311 map->r_addr = buf; 310 map->r_addr = buf;
312 311
313 dprintk("RPC: %sregistering [%u, %u, %s, '%s'] with " 312 dprintk("RPC: %sregistering [%u, %u, %s, '%s'] with "
@@ -422,8 +421,8 @@ int rpcb_getport_sync(struct sockaddr_in *sin, u32 prog, u32 vers, int prot)
422 struct rpc_clnt *rpcb_clnt; 421 struct rpc_clnt *rpcb_clnt;
423 int status; 422 int status;
424 423
425 dprintk("RPC: %s(" NIPQUAD_FMT ", %u, %u, %d)\n", 424 dprintk("RPC: %s(%pI4, %u, %u, %d)\n",
426 __func__, NIPQUAD(sin->sin_addr.s_addr), prog, vers, prot); 425 __func__, &sin->sin_addr.s_addr, prog, vers, prot);
427 426
428 rpcb_clnt = rpcb_create(NULL, (struct sockaddr *)sin, 427 rpcb_clnt = rpcb_create(NULL, (struct sockaddr *)sin,
429 sizeof(*sin), prot, RPCBVERS_2); 428 sizeof(*sin), prot, RPCBVERS_2);