|
@@ -3713,7 +3713,7 @@ SYSCALL_DEFINE1(sched_getscheduler, pid_t, pid)
|
|
*/
|
|
*/
|
|
SYSCALL_DEFINE2(sched_getparam, pid_t, pid, struct sched_param __user *, param)
|
|
SYSCALL_DEFINE2(sched_getparam, pid_t, pid, struct sched_param __user *, param)
|
|
{
|
|
{
|
|
- struct sched_param lp;
|
|
|
|
|
|
+ struct sched_param lp = { .sched_priority = 0 };
|
|
struct task_struct *p;
|
|
struct task_struct *p;
|
|
int retval;
|
|
int retval;
|
|
|
|
|
|
@@ -3730,11 +3730,8 @@ SYSCALL_DEFINE2(sched_getparam, pid_t, pid, struct sched_param __user *, param)
|
|
if (retval)
|
|
if (retval)
|
|
goto out_unlock;
|
|
goto out_unlock;
|
|
|
|
|
|
- if (task_has_dl_policy(p)) {
|
|
|
|
- retval = -EINVAL;
|
|
|
|
- goto out_unlock;
|
|
|
|
- }
|
|
|
|
- lp.sched_priority = p->rt_priority;
|
|
|
|
|
|
+ if (task_has_rt_policy(p))
|
|
|
|
+ lp.sched_priority = p->rt_priority;
|
|
rcu_read_unlock();
|
|
rcu_read_unlock();
|
|
|
|
|
|
/*
|
|
/*
|