diff options
Diffstat (limited to 'include/linux/reiserfs_acl.h')
-rw-r--r-- | include/linux/reiserfs_acl.h | 53 |
1 files changed, 25 insertions, 28 deletions
diff --git a/include/linux/reiserfs_acl.h b/include/linux/reiserfs_acl.h index 2aef9c3f5ce8..0a3605099c44 100644 --- a/include/linux/reiserfs_acl.h +++ b/include/linux/reiserfs_acl.h | |||
@@ -1,33 +1,32 @@ | |||
1 | #include <linux/init.h> | 1 | #include <linux/init.h> |
2 | #include <linux/posix_acl.h> | 2 | #include <linux/posix_acl.h> |
3 | #include <linux/xattr_acl.h> | ||
4 | 3 | ||
5 | #define REISERFS_ACL_VERSION 0x0001 | 4 | #define REISERFS_ACL_VERSION 0x0001 |
6 | 5 | ||
7 | typedef struct { | 6 | typedef struct { |
8 | __le16 e_tag; | 7 | __le16 e_tag; |
9 | __le16 e_perm; | 8 | __le16 e_perm; |
10 | __le32 e_id; | 9 | __le32 e_id; |
11 | } reiserfs_acl_entry; | 10 | } reiserfs_acl_entry; |
12 | 11 | ||
13 | typedef struct { | 12 | typedef struct { |
14 | __le16 e_tag; | 13 | __le16 e_tag; |
15 | __le16 e_perm; | 14 | __le16 e_perm; |
16 | } reiserfs_acl_entry_short; | 15 | } reiserfs_acl_entry_short; |
17 | 16 | ||
18 | typedef struct { | 17 | typedef struct { |
19 | __le32 a_version; | 18 | __le32 a_version; |
20 | } reiserfs_acl_header; | 19 | } reiserfs_acl_header; |
21 | 20 | ||
22 | static inline size_t reiserfs_acl_size(int count) | 21 | static inline size_t reiserfs_acl_size(int count) |
23 | { | 22 | { |
24 | if (count <= 4) { | 23 | if (count <= 4) { |
25 | return sizeof(reiserfs_acl_header) + | 24 | return sizeof(reiserfs_acl_header) + |
26 | count * sizeof(reiserfs_acl_entry_short); | 25 | count * sizeof(reiserfs_acl_entry_short); |
27 | } else { | 26 | } else { |
28 | return sizeof(reiserfs_acl_header) + | 27 | return sizeof(reiserfs_acl_header) + |
29 | 4 * sizeof(reiserfs_acl_entry_short) + | 28 | 4 * sizeof(reiserfs_acl_entry_short) + |
30 | (count - 4) * sizeof(reiserfs_acl_entry); | 29 | (count - 4) * sizeof(reiserfs_acl_entry); |
31 | } | 30 | } |
32 | } | 31 | } |
33 | 32 | ||
@@ -47,14 +46,14 @@ static inline int reiserfs_acl_count(size_t size) | |||
47 | } | 46 | } |
48 | } | 47 | } |
49 | 48 | ||
50 | |||
51 | #ifdef CONFIG_REISERFS_FS_POSIX_ACL | 49 | #ifdef CONFIG_REISERFS_FS_POSIX_ACL |
52 | struct posix_acl * reiserfs_get_acl(struct inode *inode, int type); | 50 | struct posix_acl *reiserfs_get_acl(struct inode *inode, int type); |
53 | int reiserfs_acl_chmod (struct inode *inode); | 51 | int reiserfs_acl_chmod(struct inode *inode); |
54 | int reiserfs_inherit_default_acl (struct inode *dir, struct dentry *dentry, struct inode *inode); | 52 | int reiserfs_inherit_default_acl(struct inode *dir, struct dentry *dentry, |
55 | int reiserfs_cache_default_acl (struct inode *dir); | 53 | struct inode *inode); |
56 | extern int reiserfs_xattr_posix_acl_init (void) __init; | 54 | int reiserfs_cache_default_acl(struct inode *dir); |
57 | extern int reiserfs_xattr_posix_acl_exit (void); | 55 | extern int reiserfs_xattr_posix_acl_init(void) __init; |
56 | extern int reiserfs_xattr_posix_acl_exit(void); | ||
58 | extern struct reiserfs_xattr_handler posix_acl_default_handler; | 57 | extern struct reiserfs_xattr_handler posix_acl_default_handler; |
59 | extern struct reiserfs_xattr_handler posix_acl_access_handler; | 58 | extern struct reiserfs_xattr_handler posix_acl_access_handler; |
60 | #else | 59 | #else |
@@ -62,28 +61,26 @@ extern struct reiserfs_xattr_handler posix_acl_access_handler; | |||
62 | #define reiserfs_get_acl NULL | 61 | #define reiserfs_get_acl NULL |
63 | #define reiserfs_cache_default_acl(inode) 0 | 62 | #define reiserfs_cache_default_acl(inode) 0 |
64 | 63 | ||
65 | static inline int | 64 | static inline int reiserfs_xattr_posix_acl_init(void) |
66 | reiserfs_xattr_posix_acl_init (void) | ||
67 | { | 65 | { |
68 | return 0; | 66 | return 0; |
69 | } | 67 | } |
70 | 68 | ||
71 | static inline int | 69 | static inline int reiserfs_xattr_posix_acl_exit(void) |
72 | reiserfs_xattr_posix_acl_exit (void) | ||
73 | { | 70 | { |
74 | return 0; | 71 | return 0; |
75 | } | 72 | } |
76 | 73 | ||
77 | static inline int | 74 | static inline int reiserfs_acl_chmod(struct inode *inode) |
78 | reiserfs_acl_chmod (struct inode *inode) | ||
79 | { | 75 | { |
80 | return 0; | 76 | return 0; |
81 | } | 77 | } |
82 | 78 | ||
83 | static inline int | 79 | static inline int |
84 | reiserfs_inherit_default_acl (const struct inode *dir, struct dentry *dentry, struct inode *inode) | 80 | reiserfs_inherit_default_acl(const struct inode *dir, struct dentry *dentry, |
81 | struct inode *inode) | ||
85 | { | 82 | { |
86 | return 0; | 83 | return 0; |
87 | } | 84 | } |
88 | 85 | ||
89 | #endif | 86 | #endif |