• Home
  • Raw
  • Download

Lines Matching refs:acl

48 	struct posix_acl *acl;  in f2fs_acl_from_disk()  local
65 acl = posix_acl_alloc(count, GFP_NOFS); in f2fs_acl_from_disk()
66 if (!acl) in f2fs_acl_from_disk()
74 acl->a_entries[i].e_tag = le16_to_cpu(entry->e_tag); in f2fs_acl_from_disk()
75 acl->a_entries[i].e_perm = le16_to_cpu(entry->e_perm); in f2fs_acl_from_disk()
77 switch (acl->a_entries[i].e_tag) { in f2fs_acl_from_disk()
87 acl->a_entries[i].e_uid = in f2fs_acl_from_disk()
94 acl->a_entries[i].e_gid = in f2fs_acl_from_disk()
106 return acl; in f2fs_acl_from_disk()
108 posix_acl_release(acl); in f2fs_acl_from_disk()
113 const struct posix_acl *acl, size_t *size) in f2fs_acl_to_disk() argument
120 acl->a_count * sizeof(struct f2fs_acl_entry), in f2fs_acl_to_disk()
128 for (i = 0; i < acl->a_count; i++) { in f2fs_acl_to_disk()
130 entry->e_tag = cpu_to_le16(acl->a_entries[i].e_tag); in f2fs_acl_to_disk()
131 entry->e_perm = cpu_to_le16(acl->a_entries[i].e_perm); in f2fs_acl_to_disk()
133 switch (acl->a_entries[i].e_tag) { in f2fs_acl_to_disk()
137 acl->a_entries[i].e_uid)); in f2fs_acl_to_disk()
144 acl->a_entries[i].e_gid)); in f2fs_acl_to_disk()
159 *size = f2fs_acl_size(acl->a_count); in f2fs_acl_to_disk()
172 struct posix_acl *acl; in __f2fs_get_acl() local
188 acl = f2fs_acl_from_disk(value, retval); in __f2fs_get_acl()
190 acl = NULL; in __f2fs_get_acl()
192 acl = ERR_PTR(retval); in __f2fs_get_acl()
195 return acl; in __f2fs_get_acl()
204 struct posix_acl *acl, struct page *ipage) in __f2fs_set_acl() argument
215 if (acl && !ipage) { in __f2fs_set_acl()
216 error = posix_acl_update_mode(inode, &mode, &acl); in __f2fs_set_acl()
226 return acl ? -EACCES : 0; in __f2fs_set_acl()
233 if (acl) { in __f2fs_set_acl()
234 value = f2fs_acl_to_disk(F2FS_I_SB(inode), acl, &size); in __f2fs_set_acl()
245 set_cached_acl(inode, type, acl); in __f2fs_set_acl()
251 int f2fs_set_acl(struct inode *inode, struct posix_acl *acl, int type) in f2fs_set_acl() argument
256 return __f2fs_set_acl(inode, type, acl, NULL); in f2fs_set_acl()
263 static struct posix_acl *f2fs_acl_clone(const struct posix_acl *acl, in f2fs_acl_clone() argument
268 if (acl) { in f2fs_acl_clone()
269 int size = sizeof(struct posix_acl) + acl->a_count * in f2fs_acl_clone()
271 clone = kmemdup(acl, size, flags); in f2fs_acl_clone()
278 static int f2fs_acl_create_masq(struct posix_acl *acl, umode_t *mode_p) in f2fs_acl_create_masq() argument
287 FOREACH_ACL_ENTRY(pa, acl, pe) { in f2fs_acl_create_masq()
333 struct posix_acl **default_acl, struct posix_acl **acl, in f2fs_acl_create() argument
340 *acl = NULL; in f2fs_acl_create()
367 *acl = clone; in f2fs_acl_create()
386 struct posix_acl *default_acl = NULL, *acl = NULL; in f2fs_init_acl() local
389 error = f2fs_acl_create(dir, &inode->i_mode, &default_acl, &acl, dpage); in f2fs_init_acl()
402 if (acl) { in f2fs_init_acl()
404 error = __f2fs_set_acl(inode, ACL_TYPE_ACCESS, acl, in f2fs_init_acl()
406 posix_acl_release(acl); in f2fs_init_acl()