diff options
author | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
---|---|---|
committer | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
commit | c71c03bda1e86c9d5198c5d83f712e695c4f2a1e (patch) | |
tree | ecb166cb3e2b7e2adb3b5e292245fefd23381ac8 /include/linux/posix_acl.h | |
parent | ea53c912f8a86a8567697115b6a0d8152beee5c8 (diff) | |
parent | 6a00f206debf8a5c8899055726ad127dbeeed098 (diff) |
Merge branch 'mpi-master' into wip-k-fmlpwip-k-fmlp
Conflicts:
litmus/sched_cedf.c
Diffstat (limited to 'include/linux/posix_acl.h')
-rw-r--r-- | include/linux/posix_acl.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/include/linux/posix_acl.h b/include/linux/posix_acl.h index 67608161df6b..54211c1cd926 100644 --- a/include/linux/posix_acl.h +++ b/include/linux/posix_acl.h | |||
@@ -71,6 +71,7 @@ posix_acl_release(struct posix_acl *acl) | |||
71 | 71 | ||
72 | /* posix_acl.c */ | 72 | /* posix_acl.c */ |
73 | 73 | ||
74 | extern void posix_acl_init(struct posix_acl *, int); | ||
74 | extern struct posix_acl *posix_acl_alloc(int, gfp_t); | 75 | extern struct posix_acl *posix_acl_alloc(int, gfp_t); |
75 | extern struct posix_acl *posix_acl_clone(const struct posix_acl *, gfp_t); | 76 | extern struct posix_acl *posix_acl_clone(const struct posix_acl *, gfp_t); |
76 | extern int posix_acl_valid(const struct posix_acl *); | 77 | extern int posix_acl_valid(const struct posix_acl *); |
@@ -108,6 +109,25 @@ static inline struct posix_acl *get_cached_acl(struct inode *inode, int type) | |||
108 | return acl; | 109 | return acl; |
109 | } | 110 | } |
110 | 111 | ||
112 | static inline int negative_cached_acl(struct inode *inode, int type) | ||
113 | { | ||
114 | struct posix_acl **p, *acl; | ||
115 | switch (type) { | ||
116 | case ACL_TYPE_ACCESS: | ||
117 | p = &inode->i_acl; | ||
118 | break; | ||
119 | case ACL_TYPE_DEFAULT: | ||
120 | p = &inode->i_default_acl; | ||
121 | break; | ||
122 | default: | ||
123 | BUG(); | ||
124 | } | ||
125 | acl = ACCESS_ONCE(*p); | ||
126 | if (acl) | ||
127 | return 0; | ||
128 | return 1; | ||
129 | } | ||
130 | |||
111 | static inline void set_cached_acl(struct inode *inode, | 131 | static inline void set_cached_acl(struct inode *inode, |
112 | int type, | 132 | int type, |
113 | struct posix_acl *acl) | 133 | struct posix_acl *acl) |