Skip to content

Commit

Permalink
NFS: nfs_rename() should not have to flush out writebacks
Browse files Browse the repository at this point in the history
We don't really support nfs servers that invalidate the file handle after a
rename, so precautions such as flushing out dirty data before renaming the
file are superfluous.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
  • Loading branch information
Trond Myklebust authored and Trond Myklebust committed Aug 4, 2010
1 parent 1b924e5 commit 0a8ebba
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions fs/nfs/dir.c
Original file line number Diff line number Diff line change
Expand Up @@ -1652,16 +1652,7 @@ static int nfs_rename(struct inode *old_dir, struct dentry *old_dentry,
}
}

/*
* ... prune child dentries and writebacks if needed.
*/
if (atomic_read(&old_dentry->d_count) > 1) {
if (S_ISREG(old_inode->i_mode))
nfs_wb_all(old_inode);
shrink_dcache_parent(old_dentry);
}
nfs_inode_return_delegation(old_inode);

if (new_inode != NULL)
nfs_inode_return_delegation(new_inode);

Expand Down

0 comments on commit 0a8ebba

Please sign in to comment.