Lines Matching refs:idmap

115 static struct posix_acl *__get_acl(struct mnt_idmap *idmap,
158 acl = inode->i_op->get_acl(idmap, dentry, type);
376 posix_acl_permission(struct mnt_idmap *idmap, struct inode *inode,
391 vfsuid = i_uid_into_vfsuid(idmap, inode);
396 vfsuid = make_vfsuid(idmap, fs_userns,
402 vfsgid = i_gid_into_vfsgid(idmap, inode);
410 vfsgid = make_vfsgid(idmap, fs_userns,
595 * @idmap: idmap of the mount @inode was found from
599 * If the dentry has been found through an idmapped mount the idmap of
600 * the vfsmount must be passed through @idmap. This function will then
601 * take care to map the inode according to @idmap before checking
606 posix_acl_chmod(struct mnt_idmap *idmap, struct dentry *dentry,
628 ret = inode->i_op->set_acl(idmap, dentry, acl, ACL_TYPE_ACCESS);
687 * @idmap: idmap of the mount @inode was found from
699 * If the inode has been found through an idmapped mount the idmap of
700 * the vfsmount must be passed through @idmap. This function will then
701 * take care to map the inode according to @idmap before checking
707 int posix_acl_update_mode(struct mnt_idmap *idmap,
719 if (!vfsgid_in_group_p(i_gid_into_vfsgid(idmap, inode)) &&
720 !capable_wrt_inode_uidgid(idmap, inode, CAP_FSETID))
875 * @idmap: idmap of the mount
888 static ssize_t vfs_posix_acl_to_xattr(struct mnt_idmap *idmap,
918 vfsuid = make_vfsuid(idmap, fs_userns, acl_e->e_uid);
923 vfsgid = make_vfsgid(idmap, fs_userns, acl_e->e_gid);
936 set_posix_acl(struct mnt_idmap *idmap, struct dentry *dentry,
948 if (!inode_owner_or_capable(idmap, inode))
956 return inode->i_op->set_acl(idmap, dentry, acl, type);
1017 int simple_set_acl(struct mnt_idmap *idmap, struct dentry *dentry,
1024 error = posix_acl_update_mode(idmap, inode,
1056 static int vfs_set_acl_idmapped_mnt(struct mnt_idmap *idmap,
1065 acl_e->e_uid = from_vfsuid(idmap, fs_userns,
1069 acl_e->e_gid = from_vfsgid(idmap, fs_userns,
1080 * @idmap: idmap of the mount
1090 int vfs_set_acl(struct mnt_idmap *idmap, struct dentry *dentry,
1110 error = vfs_set_acl_idmapped_mnt(idmap, i_user_ns(inode), kacl);
1122 error = may_write_xattr(idmap, inode);
1126 error = security_inode_set_acl(idmap, dentry, acl_name, kacl);
1135 error = set_posix_acl(idmap, dentry, acl_type, kacl);
1158 * @idmap: idmap of the mount
1167 struct posix_acl *vfs_get_acl(struct mnt_idmap *idmap,
1182 error = security_inode_get_acl(idmap, dentry, acl_name);
1191 acl = __get_acl(idmap, dentry, inode, acl_type);
1203 * @idmap: idmap of the mount
1211 int vfs_remove_acl(struct mnt_idmap *idmap, struct dentry *dentry,
1230 error = may_write_xattr(idmap, inode);
1234 error = security_inode_remove_acl(idmap, dentry, acl_name);
1243 error = set_posix_acl(idmap, dentry, acl_type, NULL);
1248 evm_inode_post_remove_acl(idmap, dentry, acl_name);
1264 int do_set_acl(struct mnt_idmap *idmap, struct dentry *dentry,
1280 error = vfs_set_acl(idmap, dentry, acl_name, acl);
1285 ssize_t do_get_acl(struct mnt_idmap *idmap, struct dentry *dentry,
1291 acl = vfs_get_acl(idmap, dentry, acl_name);
1295 error = vfs_posix_acl_to_xattr(idmap, d_inode(dentry),