]> git.proxmox.com Git - mirror_zfs.git/blobdiff - include/sys/zfs_acl.h
ztest: scrub ddt repair
[mirror_zfs.git] / include / sys / zfs_acl.h
index b6ed4390f86d98bc4c03c3a2bd0b78a9c0d13f0d..6d3db50416088ff2ac86745a54c5c7a63ca98738 100644 (file)
@@ -47,7 +47,8 @@ struct znode_phys;
 #define        ZFS_ACL_VERSION         ZFS_ACL_VERSION_FUID
 
 /*
- * ZFS ACLs are store in various forms.
+ * ZFS ACLs (Access Control Lists) are stored in various forms.
+ *
  * Files created with ACL version ZFS_ACL_VERSION_INITIAL
  * will all be created with fixed length ACEs of type
  * zfs_oldace_t.
@@ -137,8 +138,8 @@ typedef struct acl_ops {
        size_t          (*ace_size)(void *acep); /* how big is this ace */
        size_t          (*ace_abstract_size)(void); /* sizeof abstract entry */
        int             (*ace_mask_off)(void); /* off of access mask in ace */
+       /* ptr to data if any */
        int             (*ace_data)(void *acep, void **datap);
-                           /* ptr to data if any */
 } acl_ops_t;
 
 /*
@@ -165,7 +166,7 @@ typedef struct zfs_acl {
        uint64_t        z_hints;        /* ACL hints (ZFS_INHERIT_ACE ...) */
        zfs_acl_node_t  *z_curr_node;   /* current node iterator is handling */
        list_t          z_acl;          /* chunks of ACE data */
-       acl_ops_t       z_ops;          /* ACL operations */
+       acl_ops_t       *z_ops;         /* ACL operations */
 } zfs_acl_t;
 
 typedef struct acl_locator_cb {
@@ -201,13 +202,13 @@ typedef struct zfs_acl_ids {
 #define        ZFS_ACL_PASSTHROUGH_X   5
 
 struct znode;
-struct zfs_sb;
+struct zfsvfs;
 
 #ifdef _KERNEL
 int zfs_acl_ids_create(struct znode *, int, vattr_t *,
     cred_t *, vsecattr_t *, zfs_acl_ids_t *);
 void zfs_acl_ids_free(zfs_acl_ids_t *);
-boolean_t zfs_acl_ids_overquota(struct zfs_sb *, zfs_acl_ids_t *);
+boolean_t zfs_acl_ids_overquota(struct zfsvfs *, zfs_acl_ids_t *, uint64_t);
 int zfs_getacl(struct znode *, vsecattr_t *, boolean_t, cred_t *);
 int zfs_setacl(struct znode *, vsecattr_t *, boolean_t, cred_t *);
 void zfs_acl_rele(void *);
@@ -224,7 +225,7 @@ int zfs_zaccess_delete(struct znode *, struct znode *, cred_t *);
 int zfs_zaccess_rename(struct znode *, struct znode *,
     struct znode *, struct znode *, cred_t *cr);
 void zfs_acl_free(zfs_acl_t *);
-int zfs_vsec_2_aclp(struct zfs_sb *, umode_t, vsecattr_t *, cred_t *,
+int zfs_vsec_2_aclp(struct zfsvfs *, umode_t, vsecattr_t *, cred_t *,
     struct zfs_fuid_info **, zfs_acl_t **);
 int zfs_aclset_common(struct znode *, zfs_acl_t *, cred_t *, dmu_tx_t *);
 uint64_t zfs_external_acl(struct znode *);
@@ -236,6 +237,7 @@ void zfs_acl_xform(struct znode *, zfs_acl_t *, cred_t *);
 void zfs_acl_data_locator(void **, uint32_t *, uint32_t, boolean_t, void *);
 uint64_t zfs_mode_compute(uint64_t, zfs_acl_t *,
     uint64_t *, uint64_t, uint64_t);
+int zfs_acl_node_read(struct znode *, boolean_t, zfs_acl_t **, boolean_t);
 int zfs_acl_chown_setattr(struct znode *);
 
 #endif