diff options
| author | Chuck Lever <chuck.lever@oracle.com> | 2012-05-21 22:46:07 -0400 |
|---|---|---|
| committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-05-22 16:45:47 -0400 |
| commit | 4bf590e08f6db3395c181618a4c14f1c39b7c4af (patch) | |
| tree | a55286e214564ef1bea4cb270258b75e849268c1 /include/linux | |
| parent | 8cab4c390b43fe34c07bd33799c1bc24be648122 (diff) | |
NFS: Add nfs_client behavior flags
"noresvport" and "discrtry" can be passed to nfs_create_rpc_client()
by setting flags in the passed-in nfs_client. This change makes it
easy to add new flags.
Note that these settings are now "sticky" over the lifetime of a
struct nfs_client, and may even be copied when an nfs_client is
cloned.
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/nfs_fs_sb.h | 3 | ||||
| -rw-r--r-- | include/linux/nfs_xdr.h | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/nfs_fs_sb.h b/include/linux/nfs_fs_sb.h index fbec57d6dc0..3a99f525234 100644 --- a/include/linux/nfs_fs_sb.h +++ b/include/linux/nfs_fs_sb.h | |||
| @@ -35,6 +35,9 @@ struct nfs_client { | |||
| 35 | #define NFS_CS_RENEWD 3 /* - renewd started */ | 35 | #define NFS_CS_RENEWD 3 /* - renewd started */ |
| 36 | #define NFS_CS_STOP_RENEW 4 /* no more state to renew */ | 36 | #define NFS_CS_STOP_RENEW 4 /* no more state to renew */ |
| 37 | #define NFS_CS_CHECK_LEASE_TIME 5 /* need to check lease time */ | 37 | #define NFS_CS_CHECK_LEASE_TIME 5 /* need to check lease time */ |
| 38 | unsigned long cl_flags; /* behavior switches */ | ||
| 39 | #define NFS_CS_NORESVPORT 0 /* - use ephemeral src port */ | ||
| 40 | #define NFS_CS_DISCRTRY 1 /* - disconnect on RPC retry */ | ||
| 38 | struct sockaddr_storage cl_addr; /* server identifier */ | 41 | struct sockaddr_storage cl_addr; /* server identifier */ |
| 39 | size_t cl_addrlen; | 42 | size_t cl_addrlen; |
| 40 | char * cl_hostname; /* hostname of server */ | 43 | char * cl_hostname; /* hostname of server */ |
diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h index 0c521cd496a..07048c012de 100644 --- a/include/linux/nfs_xdr.h +++ b/include/linux/nfs_xdr.h | |||
| @@ -1399,7 +1399,7 @@ struct nfs_rpc_ops { | |||
| 1399 | struct iattr *iattr); | 1399 | struct iattr *iattr); |
| 1400 | struct nfs_client * | 1400 | struct nfs_client * |
| 1401 | (*init_client) (struct nfs_client *, const struct rpc_timeout *, | 1401 | (*init_client) (struct nfs_client *, const struct rpc_timeout *, |
| 1402 | const char *, rpc_authflavor_t, int); | 1402 | const char *, rpc_authflavor_t); |
| 1403 | }; | 1403 | }; |
| 1404 | 1404 | ||
| 1405 | /* | 1405 | /* |
