mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 08:30:52 +07:00
ovl: update cache version of impure parent on rename
ovl_rename() updates dir cache version for impure old parent if an entry with copy up origin is moved into old parent, but it did not update cache version if the entry moved out of old parent has a copy up origin. [SzM] Same for new dir: we updated the version if an entry with origin was moved in, but not if an entry with origin was moved out. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
This commit is contained in:
parent
a0c5ad307a
commit
f30536f0f9
@ -1075,9 +1075,10 @@ static int ovl_rename(struct inode *olddir, struct dentry *old,
|
||||
drop_nlink(d_inode(new));
|
||||
}
|
||||
|
||||
ovl_dentry_version_inc(old->d_parent,
|
||||
!overwrite && ovl_type_origin(new));
|
||||
ovl_dentry_version_inc(new->d_parent, ovl_type_origin(old));
|
||||
ovl_dentry_version_inc(old->d_parent, ovl_type_origin(old) ||
|
||||
(!overwrite && ovl_type_origin(new)));
|
||||
ovl_dentry_version_inc(new->d_parent, ovl_type_origin(old) ||
|
||||
(d_inode(new) && ovl_type_origin(new)));
|
||||
|
||||
out_dput:
|
||||
dput(newdentry);
|
||||
|
Loading…
Reference in New Issue
Block a user