1*4882a593Smuzhiyun /* 2*4882a593Smuzhiyun * GRUB -- GRand Unified Bootloader 3*4882a593Smuzhiyun * Copyright (C) 1999,2000,2001,2002,2003,2004 Free Software Foundation, Inc. 4*4882a593Smuzhiyun * 5*4882a593Smuzhiyun * SPDX-License-Identifier: GPL-2.0+ 6*4882a593Smuzhiyun */ 7*4882a593Smuzhiyun /* 8*4882a593Smuzhiyun * Copyright 2007 Sun Microsystems, Inc. All rights reserved. 9*4882a593Smuzhiyun * Use is subject to license terms. 10*4882a593Smuzhiyun */ 11*4882a593Smuzhiyun 12*4882a593Smuzhiyun #ifndef _SYS_FS_ZFS_ACL_H 13*4882a593Smuzhiyun #define _SYS_FS_ZFS_ACL_H 14*4882a593Smuzhiyun 15*4882a593Smuzhiyun typedef struct zfs_oldace { 16*4882a593Smuzhiyun uint32_t z_fuid; /* "who" */ 17*4882a593Smuzhiyun uint32_t z_access_mask; /* access mask */ 18*4882a593Smuzhiyun uint16_t z_flags; /* flags, i.e inheritance */ 19*4882a593Smuzhiyun uint16_t z_type; /* type of entry allow/deny */ 20*4882a593Smuzhiyun } zfs_oldace_t; 21*4882a593Smuzhiyun 22*4882a593Smuzhiyun #define ACE_SLOT_CNT 6 23*4882a593Smuzhiyun 24*4882a593Smuzhiyun typedef struct zfs_znode_acl_v0 { 25*4882a593Smuzhiyun uint64_t z_acl_extern_obj; /* ext acl pieces */ 26*4882a593Smuzhiyun uint32_t z_acl_count; /* Number of ACEs */ 27*4882a593Smuzhiyun uint16_t z_acl_version; /* acl version */ 28*4882a593Smuzhiyun uint16_t z_acl_pad; /* pad */ 29*4882a593Smuzhiyun zfs_oldace_t z_ace_data[ACE_SLOT_CNT]; /* 6 standard ACEs */ 30*4882a593Smuzhiyun } zfs_znode_acl_v0_t; 31*4882a593Smuzhiyun 32*4882a593Smuzhiyun #define ZFS_ACE_SPACE (sizeof(zfs_oldace_t) * ACE_SLOT_CNT) 33*4882a593Smuzhiyun 34*4882a593Smuzhiyun typedef struct zfs_znode_acl { 35*4882a593Smuzhiyun uint64_t z_acl_extern_obj; /* ext acl pieces */ 36*4882a593Smuzhiyun uint32_t z_acl_size; /* Number of bytes in ACL */ 37*4882a593Smuzhiyun uint16_t z_acl_version; /* acl version */ 38*4882a593Smuzhiyun uint16_t z_acl_count; /* ace count */ 39*4882a593Smuzhiyun uint8_t z_ace_data[ZFS_ACE_SPACE]; /* space for embedded ACEs */ 40*4882a593Smuzhiyun } zfs_znode_acl_t; 41*4882a593Smuzhiyun 42*4882a593Smuzhiyun 43*4882a593Smuzhiyun #endif /* _SYS_FS_ZFS_ACL_H */ 44