Lines Matching refs:acl
24 struct posix_acl *acl; in btrfs_get_acl() local
45 acl = posix_acl_from_xattr(&init_user_ns, value, size); in btrfs_get_acl()
47 acl = NULL; in btrfs_get_acl()
49 acl = ERR_PTR(size); in btrfs_get_acl()
52 return acl; in btrfs_get_acl()
56 struct inode *inode, struct posix_acl *acl, int type) in __btrfs_set_acl() argument
68 return acl ? -EINVAL : 0; in __btrfs_set_acl()
75 if (acl) { in __btrfs_set_acl()
78 size = posix_acl_xattr_size(acl->a_count); in __btrfs_set_acl()
91 ret = posix_acl_to_xattr(&init_user_ns, acl, value, size); in __btrfs_set_acl()
105 set_cached_acl(inode, type, acl); in __btrfs_set_acl()
110 int btrfs_set_acl(struct inode *inode, struct posix_acl *acl, int type) in btrfs_set_acl() argument
115 if (type == ACL_TYPE_ACCESS && acl) { in btrfs_set_acl()
116 ret = posix_acl_update_mode(inode, &inode->i_mode, &acl); in btrfs_set_acl()
120 ret = __btrfs_set_acl(NULL, inode, acl, type); in btrfs_set_acl()
129 struct posix_acl *default_acl, *acl; in btrfs_init_acl() local
136 ret = posix_acl_create(dir, &inode->i_mode, &default_acl, &acl); in btrfs_init_acl()
146 if (acl) { in btrfs_init_acl()
148 ret = __btrfs_set_acl(trans, inode, acl, in btrfs_init_acl()
150 posix_acl_release(acl); in btrfs_init_acl()
153 if (!default_acl && !acl) in btrfs_init_acl()