From: Trond Myklebust Date: Fri, 28 Oct 2005 02:12:41 +0000 (-0400) Subject: NFS: Optimise attribute revalidation on close(). X-Git-Tag: v2.6.15-rc1~733^2~44 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3338c143b4fde2d256016b63043ec8e2c93eba19;p=platform%2Fupstream%2Fkernel-adaptation-pc.git NFS: Optimise attribute revalidation on close(). Only force a getattr in nfs_file_flush() if the attribute cache is stale. Signed-off-by: Trond Myklebust --- diff --git a/fs/nfs/file.c b/fs/nfs/file.c index 572d859..57d3e77 100644 --- a/fs/nfs/file.c +++ b/fs/nfs/file.c @@ -205,8 +205,8 @@ nfs_file_flush(struct file *file) if (!status) { status = ctx->error; ctx->error = 0; - if (!status && !nfs_have_delegation(inode, FMODE_READ)) - __nfs_revalidate_inode(NFS_SERVER(inode), inode); + if (!status) + nfs_revalidate_inode(NFS_SERVER(inode), inode); } unlock_kernel(); return status;