summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-05-05 14:08:43 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2017-05-05 14:08:43 -0400
commite579dde654fc2c6b0d3e4b77a9a4b2d2405c510e (patch)
treefe507a2904fb302e964831a5ed079cb58ee44c37 /kernel
parentaf82455f7dbd9dc20244d80d033721b30d22c065 (diff)
parentd66bb1607e2d8d384e53f3d93db5c18483c8c4f7 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace
Pull namespace updates from Eric Biederman: "This is a set of small fixes that were mostly stumbled over during more significant development. This proc fix and the fix to posix-timers are the most significant of the lot. There is a lot of good development going on but unfortunately it didn't quite make the merge window" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace: proc: Fix unbalanced hard link numbers signal: Make kill_proc_info static rlimit: Properly call security_task_setrlimit signal: Remove unused definition of sig_user_definied ia64: Remove unused IA64_TASK_SIGHAND_OFFSET and IA64_SIGHAND_SIGLOCK_OFFSET ipc: Remove unused declaration of recompute_msgmni posix-timers: Correct sanity check in posix_cpu_nsleep sysctl: Remove dead register_sysctl_root
Diffstat (limited to 'kernel')
-rw-r--r--kernel/signal.c2
-rw-r--r--kernel/sys.c3
-rw-r--r--kernel/time/posix-cpu-timers.c2
3 files changed, 3 insertions, 4 deletions
diff --git a/kernel/signal.c b/kernel/signal.c
index 7e59ebc2c25e..a8c54f384553 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -1318,7 +1318,7 @@ int kill_pid_info(int sig, struct siginfo *info, struct pid *pid)
1318 } 1318 }
1319} 1319}
1320 1320
1321int kill_proc_info(int sig, struct siginfo *info, pid_t pid) 1321static int kill_proc_info(int sig, struct siginfo *info, pid_t pid)
1322{ 1322{
1323 int error; 1323 int error;
1324 rcu_read_lock(); 1324 rcu_read_lock();
diff --git a/kernel/sys.c b/kernel/sys.c
index 196c7134bee6..8a94b4eabcaa 100644
--- a/kernel/sys.c
+++ b/kernel/sys.c
@@ -1396,8 +1396,7 @@ int do_prlimit(struct task_struct *tsk, unsigned int resource,
1396 !capable(CAP_SYS_RESOURCE)) 1396 !capable(CAP_SYS_RESOURCE))
1397 retval = -EPERM; 1397 retval = -EPERM;
1398 if (!retval) 1398 if (!retval)
1399 retval = security_task_setrlimit(tsk->group_leader, 1399 retval = security_task_setrlimit(tsk, resource, new_rlim);
1400 resource, new_rlim);
1401 if (resource == RLIMIT_CPU && new_rlim->rlim_cur == 0) { 1400 if (resource == RLIMIT_CPU && new_rlim->rlim_cur == 0) {
1402 /* 1401 /*
1403 * The caller is asking for an immediate RLIMIT_CPU 1402 * The caller is asking for an immediate RLIMIT_CPU
diff --git a/kernel/time/posix-cpu-timers.c b/kernel/time/posix-cpu-timers.c
index 949e434d3536..1370f067fb51 100644
--- a/kernel/time/posix-cpu-timers.c
+++ b/kernel/time/posix-cpu-timers.c
@@ -1318,7 +1318,7 @@ static int posix_cpu_nsleep(const clockid_t which_clock, int flags,
1318 */ 1318 */
1319 if (CPUCLOCK_PERTHREAD(which_clock) && 1319 if (CPUCLOCK_PERTHREAD(which_clock) &&
1320 (CPUCLOCK_PID(which_clock) == 0 || 1320 (CPUCLOCK_PID(which_clock) == 0 ||
1321 CPUCLOCK_PID(which_clock) == current->pid)) 1321 CPUCLOCK_PID(which_clock) == task_pid_vnr(current)))
1322 return -EINVAL; 1322 return -EINVAL;
1323 1323
1324 error = do_cpu_nanosleep(which_clock, flags, rqtp, &it); 1324 error = do_cpu_nanosleep(which_clock, flags, rqtp, &it);