46#define EXT4_XATTR_MAGIC 0xEA020000
49#define EXT4_XATTR_REFCOUNT_MAX 1024
52#define EXT4_XATTR_INDEX_USER 1
53#define EXT4_XATTR_INDEX_POSIX_ACL_ACCESS 2
54#define EXT4_XATTR_INDEX_POSIX_ACL_DEFAULT 3
55#define EXT4_XATTR_INDEX_TRUSTED 4
56#define EXT4_XATTR_INDEX_LUSTRE 5
57#define EXT4_XATTR_INDEX_SECURITY 6
58#define EXT4_XATTR_INDEX_SYSTEM 7
59#define EXT4_XATTR_INDEX_RICHACL 8
60#define EXT4_XATTR_INDEX_ENCRYPTION 9
89#define EXT4_GOOD_OLD_INODE_SIZE EXT2_GOOD_OLD_INODE_SIZE
91#define EXT4_XATTR_PAD_BITS 2
92#define EXT4_XATTR_PAD (1<<EXT4_XATTR_PAD_BITS)
93#define EXT4_XATTR_ROUND (EXT4_XATTR_PAD-1)
94#define EXT4_XATTR_LEN(name_len) \
95 (((name_len) + EXT4_XATTR_ROUND + \
96 sizeof(struct ext4_xattr_entry)) & ~EXT4_XATTR_ROUND)
97#define EXT4_XATTR_NEXT(entry) \
98 ((struct ext4_xattr_entry *)( \
99 (char *)(entry) + EXT4_XATTR_LEN((entry)->e_name_len)))
100#define EXT4_XATTR_SIZE(size) \
101 (((size) + EXT4_XATTR_ROUND) & ~EXT4_XATTR_ROUND)
102#define EXT4_XATTR_NAME(entry) \
103 ((char *)((entry) + 1))
105#define EXT4_XATTR_IHDR(raw_inode) \
106 ((struct ext4_xattr_ibody_header *) \
107 ((char *)raw_inode + \
108 EXT4_GOOD_OLD_INODE_SIZE + \
109 (raw_inode)->i_extra_isize))
110#define EXT4_XATTR_IFIRST(hdr) \
111 ((struct ext4_xattr_entry *)((hdr)+1))
113#define EXT4_XATTR_BHDR(block) \
114 ((struct ext4_xattr_header *)((block)->b_data))
115#define EXT4_XATTR_ENTRY(ptr) \
116 ((struct ext4_xattr_entry *)(ptr))
117#define EXT4_XATTR_BFIRST(block) \
118 EXT4_XATTR_ENTRY(EXT4_XATTR_BHDR(block)+1)
119#define EXT4_XATTR_IS_LAST_ENTRY(entry) \
120 (*(__le32 *)(entry) == 0)
122#define EXT4_ZERO_XATTR_VALUE ((void *)-1)
162#define EXT4_XATTR_ITERATE_CONT 0
163#define EXT4_XATTR_ITERATE_STOP 1
164#define EXT4_XATTR_ITERATE_PAUSE 2
172 const char *
name,
size_t name_len,
const void *
data,
176 const char *
name,
size_t name_len,
const void *
data,
180 const char *
name,
size_t name_len);
183 const char *
name,
size_t name_len,
void *
buf,
184 size_t buf_size,
size_t *data_size);
194 __u8 *name_index,
size_t *name_len,
198 size_t *ret_prefix_len);
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLenum GLuint GLenum GLsizei const GLchar * buf
int ext4_fs_get_xattr(struct ext4_xattr_ref *ref, __u8 name_index, const char *name, size_t name_len, void *buf, size_t buf_size, size_t *data_size)
int ext4_fs_set_xattr(struct ext4_xattr_ref *ref, __u8 name_index, const char *name, size_t name_len, const void *data, size_t data_size, BOOL replace)
int ext4_fs_set_xattr_ordered(struct ext4_xattr_ref *ref, __u8 name_index, const char *name, size_t name_len, const void *data, size_t data_size)
const char * ext4_extract_xattr_name(const char *full_name, size_t full_name_len, __u8 *name_index, size_t *name_len, BOOL *found)
void ext4_fs_xattr_iterate_reset(struct ext4_xattr_ref *ref)
void ext4_fs_xattr_iterate(struct ext4_xattr_ref *ref, int(*iter)(struct ext4_xattr_ref *ref, struct ext4_xattr_item *item, BOOL is_last))
void ext4_xattr_purge_items(struct ext4_xattr_ref *xattr_ref)
const char * ext4_get_xattr_name_prefix(__u8 name_index, size_t *ret_prefix_len)
int ext4_fs_remove_xattr(struct ext4_xattr_ref *ref, __u8 name_index, const char *name, size_t name_len)
int ext4_fs_put_xattr_ref(struct ext4_xattr_ref *ref)
int ext4_fs_get_xattr_ref(PEXT2_IRP_CONTEXT IrpContext, PEXT2_VCB fs, PEXT2_MCB inode_ref, struct ext4_xattr_ref *ref)
INT replace(TCHAR source[MAX_PATH], TCHAR dest[MAX_PATH], DWORD dwFlags, BOOL *doMore)
struct list_head list_node
struct ext4_xattr_item * iter_from
PEXT2_IRP_CONTEXT IrpContext
struct buffer_head * block_bh
struct list_head ordered_list