aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2007-09-11 18:00:36 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2007-10-09 17:16:51 -0400
commit4784cb51a3f66d401f8a08810231aa7dc8f44e43 (patch)
treea04a91b851bba89b0507a72e31cdee716d31bbf4 /net
parente65fe3976f594603ed7b1b4a99d3e9b867f573ea (diff)
SUNRPC: Retry bad rpcbind replies
When a server returns a bad rpcbind reply, make rpcbind client recovery logic retry with an older protocol version. Older versions are more likely to work correctly. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/rpcb_clnt.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/sunrpc/rpcb_clnt.c b/net/sunrpc/rpcb_clnt.c
index 34738c5cf312..a0c9f6905517 100644
--- a/net/sunrpc/rpcb_clnt.c
+++ b/net/sunrpc/rpcb_clnt.c
@@ -446,6 +446,10 @@ static void rpcb_getport_done(struct rpc_task *child, void *data)
446 struct rpc_xprt *xprt = map->r_xprt; 446 struct rpc_xprt *xprt = map->r_xprt;
447 int status = child->tk_status; 447 int status = child->tk_status;
448 448
449 /* Garbage reply: retry with a lesser rpcbind version */
450 if (status == -EIO)
451 status = -EPROTONOSUPPORT;
452
449 /* rpcbind server doesn't support this rpcbind protocol version */ 453 /* rpcbind server doesn't support this rpcbind protocol version */
450 if (status == -EPROTONOSUPPORT) 454 if (status == -EPROTONOSUPPORT)
451 xprt->bind_index++; 455 xprt->bind_index++;