summaryrefslogtreecommitdiff
path: root/fs/overlayfs/super.c
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@redhat.com>2016-12-16 13:02:55 +0300
committerMiklos Szeredi <mszeredi@redhat.com>2016-12-16 13:02:55 +0300
commitc412ce498396097cb96b3e24e062752312a962c9 (patch)
tree607029b78cb046e211919cfc6f7cc796a0ad44c9 /fs/overlayfs/super.c
parent99f5d08e3640c8319f353e6c883da150c48067f6 (diff)
downloadlinux-c412ce498396097cb96b3e24e062752312a962c9.tar.xz
ovl: add ovl_dentry_is_whiteout()
And use it instead of ovl_dentry_is_opaque() where appropriate. Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs/overlayfs/super.c')
-rw-r--r--fs/overlayfs/super.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c
index e296312005cc..aa0427dabea8 100644
--- a/fs/overlayfs/super.c
+++ b/fs/overlayfs/super.c
@@ -209,6 +209,11 @@ bool ovl_dentry_is_opaque(struct dentry *dentry)
return oe->opaque;
}
+bool ovl_dentry_is_whiteout(struct dentry *dentry)
+{
+ return !dentry->d_inode && ovl_dentry_is_opaque(dentry);
+}
+
void ovl_dentry_set_opaque(struct dentry *dentry, bool opaque)
{
struct ovl_entry *oe = dentry->d_fsdata;