diff options
author | Chris Wright <chrisw@sous-sol.org> | 2006-03-25 03:07:41 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-25 08:22:56 -0800 |
commit | 12b5989be10011387a9da5dee82e5c0d6f9d02e7 (patch) | |
tree | 74da71d407bf26bf97c639bb2b473de233a736ac /include/linux/capability.h | |
parent | 77d47582c2345e071df02afaf9191641009287c4 (diff) | |
download | linux-12b5989be10011387a9da5dee82e5c0d6f9d02e7.tar.gz linux-12b5989be10011387a9da5dee82e5c0d6f9d02e7.tar.bz2 linux-12b5989be10011387a9da5dee82e5c0d6f9d02e7.zip |
[PATCH] refactor capable() to one implementation, add __capable() helper
Move capable() to kernel/capability.c and eliminate duplicate
implementations. Add __capable() function which can be used to check for
capabiilty of any process.
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/linux/capability.h')
-rw-r--r-- | include/linux/capability.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/capability.h b/include/linux/capability.h index 5a23ce752629..6548b35ab9f6 100644 --- a/include/linux/capability.h +++ b/include/linux/capability.h @@ -357,7 +357,8 @@ static inline kernel_cap_t cap_invert(kernel_cap_t c) #define cap_is_fs_cap(c) (CAP_TO_MASK(c) & CAP_FS_MASK) -extern int capable(int cap); +int capable(int cap); +int __capable(struct task_struct *t, int cap); #endif /* __KERNEL__ */ |