summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorMiklos Szeredi <mszeredi@suse.cz>2014-11-20 16:40:01 +0100
committerMiklos Szeredi <mszeredi@suse.cz>2014-11-20 16:40:01 +0100
commit71d509280f7e92eb60ae6b7c78c20afafff060c7 (patch)
treec241d261feb9331eaee8dd1137884e86d2c3aae9 /fs
parent91c77947133f7aef851b625701e182d3f99d14a9 (diff)
downloadop-kernel-dev-71d509280f7e92eb60ae6b7c78c20afafff060c7.zip
op-kernel-dev-71d509280f7e92eb60ae6b7c78c20afafff060c7.tar.gz
ovl: use lockless_dereference() for upperdentry
Don't open code lockless_dereference() in ovl_upperdentry_dereference(). Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Diffstat (limited to 'fs')
-rw-r--r--fs/overlayfs/super.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c
index eee7a62..f16d318 100644
--- a/fs/overlayfs/super.c
+++ b/fs/overlayfs/super.c
@@ -84,12 +84,7 @@ enum ovl_path_type ovl_path_type(struct dentry *dentry)
static struct dentry *ovl_upperdentry_dereference(struct ovl_entry *oe)
{
- struct dentry *upperdentry = ACCESS_ONCE(oe->__upperdentry);
- /*
- * Make sure to order reads to upperdentry wrt ovl_dentry_update()
- */
- smp_read_barrier_depends();
- return upperdentry;
+ return lockless_dereference(oe->__upperdentry);
}
void ovl_path_upper(struct dentry *dentry, struct path *path)
OpenPOWER on IntegriCloud