nfsd: Add fine grained protection for the nfs4_file->fi_stateids list
Access to this list is currently serialized by the client_mutex. Add finer grained locking around this list in preparation for its removal. Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
This commit is contained in:

committed by
J. Bruce Fields

parent
d6c249b4d4
commit
1d31a2531a
@@ -377,6 +377,7 @@ static inline struct nfs4_lockowner * lockowner(struct nfs4_stateowner *so)
|
||||
/* nfs4_file: a file opened by some number of (open) nfs4_stateowners. */
|
||||
struct nfs4_file {
|
||||
atomic_t fi_ref;
|
||||
spinlock_t fi_lock;
|
||||
struct hlist_node fi_hash; /* hash by "struct inode *" */
|
||||
struct list_head fi_stateids;
|
||||
struct list_head fi_delegations;
|
||||
|
Reference in New Issue
Block a user