NFS: Clean up NFS writeback flush code

The only user of nfs_sync_mapping_range() is nfs_getattr(), which uses it
to flush out the entire inode without sending a commit. We therefore
replace nfs_sync_mapping_range with a more appropriate helper.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
Trond Myklebust 2007-07-20 13:13:28 -04:00
parent 90e9a3f9b0
commit ed90ef51a3
3 changed files with 16 additions and 29 deletions

View file

@ -431,7 +431,7 @@ int nfs_getattr(struct vfsmount *mnt, struct dentry *dentry, struct kstat *stat)
/* Flush out writes to the server in order to update c/mtime */
if (S_ISREG(inode->i_mode))
nfs_sync_mapping_range(inode->i_mapping, 0, 0, FLUSH_NOCOMMIT);
nfs_wb_nocommit(inode);
/*
* We may force a getattr if the user cares about atime.