diff options
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index a2be2d055299..a234fbee1238 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -4162,10 +4162,8 @@ do_sched_setscheduler(pid_t pid, int policy, struct sched_param __user *param) | |||
4162 | read_unlock_irq(&tasklist_lock); | 4162 | read_unlock_irq(&tasklist_lock); |
4163 | return -ESRCH; | 4163 | return -ESRCH; |
4164 | } | 4164 | } |
4165 | get_task_struct(p); | ||
4166 | read_unlock_irq(&tasklist_lock); | ||
4167 | retval = sched_setscheduler(p, policy, &lparam); | 4165 | retval = sched_setscheduler(p, policy, &lparam); |
4168 | put_task_struct(p); | 4166 | read_unlock_irq(&tasklist_lock); |
4169 | 4167 | ||
4170 | return retval; | 4168 | return retval; |
4171 | } | 4169 | } |