diff options
author | trasz <trasz@FreeBSD.org> | 2009-05-26 08:21:59 +0000 |
---|---|---|
committer | trasz <trasz@FreeBSD.org> | 2009-05-26 08:21:59 +0000 |
commit | 0bf624fc06bae6de575f74e42fdd761ee17a38a9 (patch) | |
tree | 8c54445946a89163e2e5e57f7c3369eb7b172652 /sys/cddl/contrib/opensolaris/common/acl | |
parent | 61ac57ee20283bf8a9b4ade769d4beb42a4247cb (diff) | |
download | FreeBSD-src-0bf624fc06bae6de575f74e42fdd761ee17a38a9.zip FreeBSD-src-0bf624fc06bae6de575f74e42fdd761ee17a38a9.tar.gz |
MFp4 changes neccessary for NFSv4 ACLs support in ZFS. This is mostly
about removing a few #ifdefs and providing compatibility wrappers and
VOP implementations to get and set an ACL; ZFS does ACL enforcement all
by itself.
Note that the VOPs are ifdefed out for now, so this change should be
a no-op.
Reviewed by: pjd
Diffstat (limited to 'sys/cddl/contrib/opensolaris/common/acl')
-rw-r--r-- | sys/cddl/contrib/opensolaris/common/acl/acl_common.c | 4 | ||||
-rw-r--r-- | sys/cddl/contrib/opensolaris/common/acl/acl_common.h | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/sys/cddl/contrib/opensolaris/common/acl/acl_common.c b/sys/cddl/contrib/opensolaris/common/acl/acl_common.c index 8d0cc85..5e8de19 100644 --- a/sys/cddl/contrib/opensolaris/common/acl/acl_common.c +++ b/sys/cddl/contrib/opensolaris/common/acl/acl_common.c @@ -424,7 +424,7 @@ cacl_free(void *ptr, size_t size) #endif } -#ifndef __FreeBSD__ +#if !defined(_KERNEL) acl_t * acl_alloc(enum acl_type type) { @@ -470,7 +470,6 @@ acl_free(acl_t *aclp) cacl_free(aclp, sizeof (acl_t)); } -#endif static uint32_t access_mask_set(int haswriteperm, int hasreadperm, int isowner, int isallow) @@ -1727,3 +1726,4 @@ out: return (error); #endif } +#endif /* _KERNEL */ diff --git a/sys/cddl/contrib/opensolaris/common/acl/acl_common.h b/sys/cddl/contrib/opensolaris/common/acl/acl_common.h index 84bd04f..85ba0bd 100644 --- a/sys/cddl/contrib/opensolaris/common/acl/acl_common.h +++ b/sys/cddl/contrib/opensolaris/common/acl/acl_common.h @@ -46,6 +46,7 @@ extern int ace_trivial(ace_t *acep, int aclcnt); extern int ace_trivial_common(void *, int, uint64_t (*walk)(void *, uint64_t, int aclcnt, uint16_t *, uint16_t *, uint32_t *mask)); +#if !defined(_KERNEL) extern acl_t *acl_alloc(acl_type_t); extern void acl_free(acl_t *aclp); extern int acl_translate(acl_t *aclp, int target_flavor, @@ -53,6 +54,7 @@ extern int acl_translate(acl_t *aclp, int target_flavor, void ksort(caddr_t v, int n, int s, int (*f)()); int cmp2acls(void *a, void *b); +#endif /* _KERNEL */ #ifdef __cplusplus } |