Skip to content

Commit b3d8ff0

Browse files
committed
nsfs: port to ns_ref_*() helpers
Stop accessing ns.count directly. Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Christian Brauner <brauner@kernel.org>
1 parent 99d33ce commit b3d8ff0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

fs/nsfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ static struct dentry *nsfs_fh_to_dentry(struct super_block *sb, struct fid *fh,
492492
VFS_WARN_ON_ONCE(ns->ops->type != fid->ns_type);
493493
VFS_WARN_ON_ONCE(ns->inum != fid->ns_inum);
494494

495-
if (!refcount_inc_not_zero(&ns->count))
495+
if (!__ns_ref_get(ns))
496496
return NULL;
497497
}
498498

0 commit comments

Comments
 (0)