aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/cgroup.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/cgroup.c')
-rw-r--r--kernel/cgroup.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index ed64ccac67c9..c8329b0c2576 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -2160,9 +2160,9 @@ retry_find_task:
2160 * only need to check permissions on one of them. 2160 * only need to check permissions on one of them.
2161 */ 2161 */
2162 tcred = __task_cred(tsk); 2162 tcred = __task_cred(tsk);
2163 if (cred->euid && 2163 if (!uid_eq(cred->euid, GLOBAL_ROOT_UID) &&
2164 cred->euid != tcred->uid && 2164 !uid_eq(cred->euid, tcred->uid) &&
2165 cred->euid != tcred->suid) { 2165 !uid_eq(cred->euid, tcred->suid)) {
2166 rcu_read_unlock(); 2166 rcu_read_unlock();
2167 ret = -EACCES; 2167 ret = -EACCES;
2168 goto out_unlock_cgroup; 2168 goto out_unlock_cgroup;