aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/client.c
diff options
context:
space:
mode:
authorRicardo Labiaga <Ricardo.Labiaga@netapp.com>2010-10-12 19:30:05 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2010-10-24 17:59:56 -0400
commit6b96724e507fecc3e6440e86426fe4f44359ed66 (patch)
tree5b38131405301f4dd536a11f44ff0d5e6785d266 /fs/nfs/client.c
parent118df3d17f11733b294ea2cd988d56ee376ef9fd (diff)
Revalidate caches on lock
Instead of blindly zapping the caches, attempt to revalidate them if the server has indicated that it uses high resolution timestamps. NFSv4 should be able to always revalidate the cache since the protocol requires the update of the change attribute on modification of the data. In reality, there are servers (the Linux NFS server for example) that do not obey this requirement and use ctime as the basis for change attribute. Long term, the server needs to be fixed. At this time, and to be on the safe side, continue zapping caches if the server indicates that it does not have a high resolution timestamp. Signed-off-by: Ricardo Labiaga <Ricardo.Labiaga@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/client.c')
-rw-r--r--fs/nfs/client.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nfs/client.c b/fs/nfs/client.c
index da2f2f024a4d..a63bce8d0596 100644
--- a/fs/nfs/client.c
+++ b/fs/nfs/client.c
@@ -915,6 +915,8 @@ static void nfs_server_set_fsinfo(struct nfs_server *server, struct nfs_fsinfo *
915 915
916 server->maxfilesize = fsinfo->maxfilesize; 916 server->maxfilesize = fsinfo->maxfilesize;
917 917
918 server->time_delta = fsinfo->time_delta;
919
918 /* We're airborne Set socket buffersize */ 920 /* We're airborne Set socket buffersize */
919 rpc_setbufsize(server->client, server->wsize + 100, server->rsize + 100); 921 rpc_setbufsize(server->client, server->wsize + 100, server->rsize + 100);
920} 922}