diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2023-08-19 17:32:23 -0400 |
---|---|---|
committer | Anna Schumaker <Anna.Schumaker@Netapp.com> | 2023-08-24 13:24:15 -0400 |
commit | d2ee413884cdbdfcfc1560526615519311a47d33 (patch) | |
tree | 68dd2b70121850e11c67df9a65247544d72d4701 /net/sunrpc/clnt.c | |
parent | 3e6ff89d2e4b605d7064686e6d8991b6f780df3f (diff) | |
download | linux-stable-d2ee413884cdbdfcfc1560526615519311a47d33.tar.gz linux-stable-d2ee413884cdbdfcfc1560526615519311a47d33.tar.bz2 linux-stable-d2ee413884cdbdfcfc1560526615519311a47d33.zip |
SUNRPC: Allow specification of TCP client connect timeout at setup
When we create a TCP transport, the connect timeout parameters are
currently fixed to be 90s. This is problematic in the pNFS flexfiles
case, where we may have multiple mirrors, and we would like to fail over
quickly to the next mirror if a data server is down.
This patch adds the ability to specify the connection parameters at RPC
client creation time.
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'net/sunrpc/clnt.c')
-rw-r--r-- | net/sunrpc/clnt.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c index ca2c6efe19c9..06df08b0ee9e 100644 --- a/net/sunrpc/clnt.c +++ b/net/sunrpc/clnt.c @@ -534,6 +534,8 @@ struct rpc_clnt *rpc_create(struct rpc_create_args *args) .servername = args->servername, .bc_xprt = args->bc_xprt, .xprtsec = args->xprtsec, + .connect_timeout = args->connect_timeout, + .reconnect_timeout = args->reconnect_timeout, }; char servername[48]; struct rpc_clnt *clnt; |