summaryrefslogtreecommitdiffstats
path: root/fs/kernfs/symlink.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/kernfs/symlink.c')
-rw-r--r--fs/kernfs/symlink.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/kernfs/symlink.c b/fs/kernfs/symlink.c
index 004c16465594..12569a738837 100644
--- a/fs/kernfs/symlink.c
+++ b/fs/kernfs/symlink.c
@@ -35,7 +35,7 @@ struct sysfs_dirent *kernfs_create_link(struct sysfs_dirent *parent,
if (!sd)
return ERR_PTR(-ENOMEM);
- if (parent->s_flags & SYSFS_FLAG_NS)
+ if (kernfs_ns_enabled(parent))
sd->s_ns = target->s_ns;
sd->s_symlink.target_sd = target;
kernfs_get(target); /* ref owned by symlink */