Lines Matching refs:aclp
54 static void acl_nfs4_trivial_from_mode(struct acl *aclp, mode_t mode);
92 _acl_append(struct acl *aclp, acl_tag_t tag, acl_perm_t perm,
97 KASSERT(aclp->acl_cnt + 1 <= ACL_MAX_ENTRIES);
99 ae = &(aclp->acl_entry[aclp->acl_cnt]);
100 aclp->acl_cnt++;
113 _acl_duplicate_entry(struct acl *aclp, unsigned int entry_index)
117 KASSERT(aclp->acl_cnt + 1 <= ACL_MAX_ENTRIES);
119 for (i = aclp->acl_cnt; i > entry_index; i--)
120 aclp->acl_entry[i] = aclp->acl_entry[i - 1];
122 aclp->acl_cnt++;
124 return (&(aclp->acl_entry[entry_index + 1]));
131 acl_nfs4_sync_acl_from_mode(struct acl *aclp, mode_t mode,
135 acl_nfs4_trivial_from_mode(aclp, mode);
140 __acl_nfs4_sync_mode_from_acl(mode_t *_mode, const struct acl *aclp)
146 KASSERT(aclp->acl_cnt <= ACL_MAX_ENTRIES);
154 for (i = 0; i < aclp->acl_cnt; i++) {
155 ae = &(aclp->acl_entry[i]);
385 struct acl *aclp, mode_t mode, int file_owner_id, int is_directory)
390 KASSERT(aclp->acl_cnt == 0);
423 _acl_append(aclp, ACL_USER_OBJ, user_allow_first,
426 _acl_append(aclp, ACL_USER_OBJ, user_deny,
429 _acl_append(aclp, ACL_GROUP_OBJ, group_deny,
433 acl_nfs4_inherit_entries(parent_aclp, aclp, mode,
436 _acl_append(aclp, ACL_USER_OBJ, user_allow, ACL_ENTRY_TYPE_ALLOW);
437 _acl_append(aclp, ACL_GROUP_OBJ, group_allow, ACL_ENTRY_TYPE_ALLOW);
438 _acl_append(aclp, ACL_EVERYONE, everyone_allow, ACL_ENTRY_TYPE_ALLOW);
460 acl_nfs4_trivial_from_mode(struct acl *aclp, mode_t mode)
463 aclp->acl_cnt = 0;
464 acl_nfs4_compute_inherited_acl_psarc(NULL, aclp, mode, -1, -1);
474 __acl_nfs4_trivial_from_mode_libc(struct acl *aclp, int mode, int canonical_six)
477 aclp->acl_cnt = 0;
478 acl_nfs4_trivial_from_mode(aclp, mode);
512 acl_nfs4_is_trivial(const struct acl *aclp, int file_owner_id)
518 if (aclp->acl_cnt > 6)
533 __acl_nfs4_sync_mode_from_acl(&tmpmode, aclp);
535 trivial = _acls_are_equal(aclp, tmpaclp);
550 acl_nfs4_check(const struct acl *aclp, int is_directory)
563 if (aclp->acl_cnt > ACL_MAX_ENTRIES || aclp->acl_cnt <= 0)
566 for (i = 0; i < aclp->acl_cnt; i++) {
567 ae = &(aclp->acl_entry[i]);