aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/internal.h
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2012-05-23 13:23:31 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2012-05-23 15:20:57 -0400
commit7b38c3682c5cab4f98751d5fe57b78a59020653d (patch)
treec6c2ea72b99b59b60a3c7ba3d142a4926664398e /fs/nfs/internal.h
parentacdeb69d9c5934a678a732b4e24770326bf9471e (diff)
NFSv4.1: Fix session initialisation races
Session initialisation is not complete until the lease manager has run. We need to ensure that both nfs4_init_session and nfs4_init_ds_session do so, and that they check for any resulting errors in clp->cl_cons_state. Only after this is done, can nfs4_ds_connect check the contents of clp->cl_exchange_flags. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> Cc: Andy Adamson <andros@netapp.com>
Diffstat (limited to 'fs/nfs/internal.h')
-rw-r--r--fs/nfs/internal.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/nfs/internal.h b/fs/nfs/internal.h
index 547f24f17d16..5ea571e8d0e9 100644
--- a/fs/nfs/internal.h
+++ b/fs/nfs/internal.h
@@ -169,7 +169,6 @@ extern struct nfs_server *nfs_clone_server(struct nfs_server *,
169 struct nfs_fattr *, 169 struct nfs_fattr *,
170 rpc_authflavor_t); 170 rpc_authflavor_t);
171extern void nfs_mark_client_ready(struct nfs_client *clp, int state); 171extern void nfs_mark_client_ready(struct nfs_client *clp, int state);
172extern int nfs4_check_client_ready(struct nfs_client *clp);
173extern struct nfs_client *nfs4_set_ds_client(struct nfs_client* mds_clp, 172extern struct nfs_client *nfs4_set_ds_client(struct nfs_client* mds_clp,
174 const struct sockaddr *ds_addr, 173 const struct sockaddr *ds_addr,
175 int ds_addrlen, int ds_proto, 174 int ds_addrlen, int ds_proto,
@@ -234,7 +233,7 @@ extern const u32 nfs41_maxwrite_overhead;
234extern struct rpc_procinfo nfs4_procedures[]; 233extern struct rpc_procinfo nfs4_procedures[];
235#endif 234#endif
236 235
237extern int nfs4_init_ds_session(struct nfs_client *clp); 236extern int nfs4_init_ds_session(struct nfs_client *, unsigned long);
238 237
239/* proc.c */ 238/* proc.c */
240void nfs_close_context(struct nfs_open_context *ctx, int is_sync); 239void nfs_close_context(struct nfs_open_context *ctx, int is_sync);