From 16413af77fe929a59bc4f3eca0e337fac19a1ebf Mon Sep 17 00:00:00 2001 From: Dmitry Kasatkin Date: Tue, 29 May 2012 11:02:21 -0700 Subject: [PATCH] --- yaml --- r: 310023 b: refs/heads/master c: 799243a389bde0de10fa21ca1ca453d2fe538b85 h: refs/heads/master i: 310021: b173426a36f7d69165fcfd4bfadaef20585567af 310019: 2db27c02b40dfafb1f62ea14f85819236e7fd92b 310015: 782f642db0aaf50b3443a20d10c504019262ec2d v: v3 --- [refs] | 2 +- trunk/fs/attr.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 32f5ba903b72..f8674ea4fc0a 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a0a9b0433767713342f9cc70f563483c38e26f30 +refs/heads/master: 799243a389bde0de10fa21ca1ca453d2fe538b85 diff --git a/trunk/fs/attr.c b/trunk/fs/attr.c index 584620e5dee5..0da90951d277 100644 --- a/trunk/fs/attr.c +++ b/trunk/fs/attr.c @@ -176,6 +176,11 @@ int notify_change(struct dentry * dentry, struct iattr * attr) return -EPERM; } + if ((ia_valid & ATTR_SIZE) && IS_I_VERSION(inode)) { + if (attr->ia_size != inode->i_size) + inode_inc_iversion(inode); + } + if ((ia_valid & ATTR_MODE)) { umode_t amode = attr->ia_mode; /* Flag setting protected by i_mutex */