diff options
-rw-r--r-- | kernel/sched.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 4107db0dc091..a5fb654ea590 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -3528,7 +3528,8 @@ recheck: | |||
3528 | */ | 3528 | */ |
3529 | if (!capable(CAP_SYS_NICE)) { | 3529 | if (!capable(CAP_SYS_NICE)) { |
3530 | /* can't change policy */ | 3530 | /* can't change policy */ |
3531 | if (policy != p->policy) | 3531 | if (policy != p->policy && |
3532 | !p->signal->rlim[RLIMIT_RTPRIO].rlim_cur) | ||
3532 | return -EPERM; | 3533 | return -EPERM; |
3533 | /* can't increase priority */ | 3534 | /* can't increase priority */ |
3534 | if (policy != SCHED_NORMAL && | 3535 | if (policy != SCHED_NORMAL && |