diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/capability.h | 1 | ||||
| -rw-r--r-- | include/linux/cred.h | 6 | 
2 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/capability.h b/include/linux/capability.h index 63f59fa8769..e3e8d9cb9b0 100644 --- a/include/linux/capability.h +++ b/include/linux/capability.h @@ -547,7 +547,6 @@ extern bool has_ns_capability_noaudit(struct task_struct *t,  				      struct user_namespace *ns, int cap);  extern bool capable(int cap);  extern bool ns_capable(struct user_namespace *ns, int cap); -extern bool task_ns_capable(struct task_struct *t, int cap);  extern bool nsown_capable(int cap);  /* audit system wants to get cap info from files as well */ diff --git a/include/linux/cred.h b/include/linux/cred.h index 40308969ed0..adadf71a732 100644 --- a/include/linux/cred.h +++ b/include/linux/cred.h @@ -358,10 +358,12 @@ static inline void put_cred(const struct cred *_cred)  #define current_security()	(current_cred_xxx(security))  #ifdef CONFIG_USER_NS -#define current_user_ns() (current_cred_xxx(user_ns)) +#define current_user_ns()	(current_cred_xxx(user_ns)) +#define task_user_ns(task)	(task_cred_xxx((task), user_ns))  #else  extern struct user_namespace init_user_ns; -#define current_user_ns() (&init_user_ns) +#define current_user_ns()	(&init_user_ns) +#define task_user_ns(task)	(&init_user_ns)  #endif  |