Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 308591
b: refs/heads/master
c: c57d1bc
h: refs/heads/master
i:
  308589: f2b168c
  308587: 07b30d9
  308583: 3925221
  308575: 153edc0
v: v3
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed May 8, 2012
1 parent 1ff146a commit 7e5f466
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 14546c337588370dced50dcaf43398939be9829e
refs/heads/master: c57d1bc5e043dbb5ba82ded07003d71a8033d899
6 changes: 5 additions & 1 deletion trunk/fs/nfs/delegation.c
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,10 @@ void nfs_inode_return_delegation_noreclaim(struct inode *inode)
* nfs_inode_return_delegation - synchronously return a delegation
* @inode: inode to process
*
* This routine will always flush any dirty data to disk on the
* assumption that if we need to return the delegation, then
* we should stop caching.
*
* Returns zero on success, or a negative errno value.
*/
int nfs_inode_return_delegation(struct inode *inode)
Expand All @@ -389,10 +393,10 @@ int nfs_inode_return_delegation(struct inode *inode)
struct nfs_delegation *delegation;
int err = 0;

nfs_wb_all(inode);
if (rcu_access_pointer(nfsi->delegation) != NULL) {
delegation = nfs_detach_delegation(nfsi, server);
if (delegation != NULL) {
nfs_wb_all(inode);
err = __nfs_inode_return_delegation(inode, delegation, 1);
}
}
Expand Down
1 change: 1 addition & 0 deletions trunk/fs/nfs/delegation.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ static inline int nfs_have_delegation(struct inode *inode, fmode_t flags)

static inline int nfs_inode_return_delegation(struct inode *inode)
{
nfs_wb_all(inode);
return 0;
}
#endif
Expand Down

0 comments on commit 7e5f466

Please sign in to comment.