diff options
author | Christian Brauner <christian.brauner@ubuntu.com> | 2021-07-27 12:48:46 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2021-08-23 13:19:13 +0200 |
commit | b0b3e44d346c91dde3899d37eddf867b9b36ffdc (patch) | |
tree | dfe4cfd5ac890730113a24a6d37039e95d7b698e /fs/btrfs | |
parent | e93ca491d03fda28db54a3d6ddc15f03a61364d7 (diff) |
btrfs: allow idmapped mkdir inode op
Enable btrfs_mkdir() to handle idmapped mounts. This is just a matter of
passing down the mount's userns.
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index a75661cd68ec..16bd56edb8e1 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -6926,7 +6926,7 @@ static int btrfs_mkdir(struct user_namespace *mnt_userns, struct inode *dir, if (err) goto out_fail; - inode = btrfs_new_inode(trans, root, &init_user_ns, dir, + inode = btrfs_new_inode(trans, root, mnt_userns, dir, dentry->d_name.name, dentry->d_name.len, btrfs_ino(BTRFS_I(dir)), objectid, S_IFDIR | mode, &index); |