summaryrefslogtreecommitdiffstats
path: root/fs/overlayfs/dir.c
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@redhat.com>2016-12-16 11:02:55 +0100
committerMiklos Szeredi <mszeredi@redhat.com>2016-12-16 11:02:55 +0100
commit38e813db61c3951ef76d071ca7d2f46c2e939b80 (patch)
tree9cd47c67b93e62a2842c975fe94b5e07f8a5b2f6 /fs/overlayfs/dir.c
parent2aff4534b6c48c465c2ba3bca310646652318e16 (diff)
downloadlinux-38e813db61c3951ef76d071ca7d2f46c2e939b80.tar.bz2
ovl: get rid of PURE type
The remainging uses of __OVL_PATH_PURE can be replaced by ovl_dentry_is_opaque(). Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/overlayfs/dir.c')
-rw-r--r--fs/overlayfs/dir.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/overlayfs/dir.c b/fs/overlayfs/dir.c
index 4582d5efc01e..76b1edccbedd 100644
--- a/fs/overlayfs/dir.c
+++ b/fs/overlayfs/dir.c
@@ -803,10 +803,7 @@ static int ovl_rename(struct inode *olddir, struct dentry *old,
if (!overwrite && OVL_TYPE_MERGE_OR_LOWER(new_type) && new_is_dir)
goto out;
} else {
- if (ovl_dentry_is_opaque(new))
- new_type = __OVL_PATH_UPPER;
- else
- new_type = __OVL_PATH_UPPER | __OVL_PATH_PURE;
+ new_type = __OVL_PATH_UPPER;
}
err = ovl_want_write(old);
@@ -826,8 +823,8 @@ static int ovl_rename(struct inode *olddir, struct dentry *old,
goto out_drop_write;
}
- old_opaque = !OVL_TYPE_PURE_UPPER(old_type);
- new_opaque = !OVL_TYPE_PURE_UPPER(new_type);
+ old_opaque = ovl_dentry_is_opaque(old);
+ new_opaque = ovl_dentry_is_opaque(new);
old_cred = ovl_override_creds(old->d_sb);