From b47ac557c6a0b23428990857259acd2e7fb1906b Mon Sep 17 00:00:00 2001 From: Steve French Date: Mon, 8 Feb 2010 17:39:58 +0000 Subject: [PATCH] --- yaml --- r: 180423 b: refs/heads/master c: ccd4bb1beb3316de4611de24d223ad761b5a7e95 h: refs/heads/master i: 180421: d0151d8f903e70f037996ed9a941aec10bac7a53 180419: 942ffd29258fe8149654a13a398d394af2ffa7b1 180415: f6277383b5d9aaf83778274aa83156ec37b4694e v: v3 --- [refs] | 2 +- trunk/fs/cifs/inode.c | 12 +++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 06f68a70805b..0c4ff77bbc42 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 301a6a317797ca362951ea21da397c05236f0070 +refs/heads/master: ccd4bb1beb3316de4611de24d223ad761b5a7e95 diff --git a/trunk/fs/cifs/inode.c b/trunk/fs/cifs/inode.c index cf18ee765590..e3fda978f481 100644 --- a/trunk/fs/cifs/inode.c +++ b/trunk/fs/cifs/inode.c @@ -1762,8 +1762,18 @@ cifs_setattr_unix(struct dentry *direntry, struct iattr *attrs) CIFS_MOUNT_MAP_SPECIAL_CHR); } - if (!rc) + if (!rc) { rc = inode_setattr(inode, attrs); + + /* force revalidate when any of these times are set since some + of the fs types (eg ext3, fat) do not have fine enough + time granularity to match protocol, and we do not have a + a way (yet) to query the server fs's time granularity (and + whether it rounds times down). + */ + if (!rc && (attrs->ia_valid & (ATTR_MTIME | ATTR_CTIME))) + cifsInode->time = 0; + } out: kfree(args); kfree(full_path);