diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2007-07-06 10:53:21 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2007-07-10 23:40:48 -0400 |
commit | 6f2e64d3e1f661095e274c9d9d47e3f39a6cf1c0 (patch) | |
tree | 59bb802bfe2df34ef5666a3d9b7a8f7c21b7247b /fs/nfs/nfs4_fs.h | |
parent | 275a5d24bf56b2d9dd4644c54a56366b89a028f1 (diff) |
NFSv4: Make the NFS state model work with the nosharedcache mount option
Consider the case where the user has mounted the remote filesystem
server:/foo on the two local directories /bar and /baz using the
nosharedcache mount option. The files /bar/file and /baz/file are
represented by different inodes in the local namespace, but refer to the
same file /foo/file on the server.
Consider the case where a process opens both /bar/file and /baz/file, then
closes /bar/file: because the nfs4_state is not shared between /bar/file
and /baz/file, the kernel will see that the nfs4_state for /bar/file is no
longer referenced, so it will send off a CLOSE rpc call. Unless the
open_owners differ, then that CLOSE call will invalidate the open state on
/baz/file too.
Conclusion: we cannot share open state owners between two different
non-shared mount instances of the same filesystem.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/nfs4_fs.h')
-rw-r--r-- | fs/nfs/nfs4_fs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/nfs/nfs4_fs.h b/fs/nfs/nfs4_fs.h index dd1aa2b598ce..6c028e734fe6 100644 --- a/fs/nfs/nfs4_fs.h +++ b/fs/nfs/nfs4_fs.h | |||
@@ -83,6 +83,7 @@ struct nfs_unique_id { | |||
83 | struct nfs4_state_owner { | 83 | struct nfs4_state_owner { |
84 | struct nfs_unique_id so_owner_id; | 84 | struct nfs_unique_id so_owner_id; |
85 | struct nfs_client *so_client; | 85 | struct nfs_client *so_client; |
86 | struct nfs_server *so_server; | ||
86 | struct rb_node so_client_node; | 87 | struct rb_node so_client_node; |
87 | 88 | ||
88 | struct rpc_cred *so_cred; /* Associated cred */ | 89 | struct rpc_cred *so_cred; /* Associated cred */ |