diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-26 01:47:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-26 01:47:03 -0400 |
commit | 84635d68be4b846ba984a89f386524153330c597 (patch) | |
tree | f9195d7eecccef6e421e483fa18755706bc2ad66 | |
parent | 45b583b10a8b438b970e95a7d1d4db22c9e35004 (diff) |
vfs: fix check_acl compile error when CONFIG_FS_POSIX_ACL is not set
Commit e77819e57f08 ("vfs: move ACL cache lookup into generic code")
didn't take the FS_POSIX_ACL config variable into account - when that is
not set, ACL's go away, and the cache helper functions do not exist,
causing compile errors like
fs/namei.c: In function 'check_acl':
fs/namei.c:191:10: error: implicit declaration of function 'negative_cached_acl'
fs/namei.c:196:2: error: implicit declaration of function 'get_cached_acl'
fs/namei.c:196:6: warning: assignment makes pointer from integer without a cast
fs/namei.c:212:11: error: implicit declaration of function 'set_cached_acl'
Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Acked-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | fs/namei.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/namei.c b/fs/namei.c index ef00b984fb20..f8c69d373793 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
@@ -176,6 +176,7 @@ EXPORT_SYMBOL(putname); | |||
176 | 176 | ||
177 | static int check_acl(struct inode *inode, int mask) | 177 | static int check_acl(struct inode *inode, int mask) |
178 | { | 178 | { |
179 | #ifdef CONFIG_FS_POSIX_ACL | ||
179 | struct posix_acl *acl; | 180 | struct posix_acl *acl; |
180 | 181 | ||
181 | /* | 182 | /* |
@@ -219,6 +220,7 @@ static int check_acl(struct inode *inode, int mask) | |||
219 | posix_acl_release(acl); | 220 | posix_acl_release(acl); |
220 | return error; | 221 | return error; |
221 | } | 222 | } |
223 | #endif | ||
222 | 224 | ||
223 | return -EAGAIN; | 225 | return -EAGAIN; |
224 | } | 226 | } |