Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 5074
b: refs/heads/master
c: d46523e
h: refs/heads/master
v: v3
  • Loading branch information
Steven Rostedt authored and Linus Torvalds committed Jul 26, 2005
1 parent 43f2964 commit c7d083e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 18586e721636527cb5177467fb17e2350615978a
refs/heads/master: d46523ea32a79fbc8cd1237f9441f45cc3f02456
2 changes: 1 addition & 1 deletion trunk/arch/ia64/sn/kernel/xpc_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ xpc_activating(void *__partid)
partid_t partid = (u64) __partid;
struct xpc_partition *part = &xpc_partitions[partid];
unsigned long irq_flags;
struct sched_param param = { sched_priority: MAX_USER_RT_PRIO - 1 };
struct sched_param param = { sched_priority: MAX_RT_PRIO - 1 };
int ret;


Expand Down
5 changes: 3 additions & 2 deletions trunk/kernel/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -3486,7 +3486,7 @@ static void __setscheduler(struct task_struct *p, int policy, int prio)
p->policy = policy;
p->rt_priority = prio;
if (policy != SCHED_NORMAL)
p->prio = MAX_USER_RT_PRIO-1 - p->rt_priority;
p->prio = MAX_RT_PRIO-1 - p->rt_priority;
else
p->prio = p->static_prio;
}
Expand Down Expand Up @@ -3518,7 +3518,8 @@ int sched_setscheduler(struct task_struct *p, int policy, struct sched_param *pa
* 1..MAX_USER_RT_PRIO-1, valid priority for SCHED_NORMAL is 0.
*/
if (param->sched_priority < 0 ||
param->sched_priority > MAX_USER_RT_PRIO-1)
(p->mm && param->sched_priority > MAX_USER_RT_PRIO-1) ||
(!p->mm && param->sched_priority > MAX_RT_PRIO-1))
return -EINVAL;
if ((policy == SCHED_NORMAL) != (param->sched_priority == 0))
return -EINVAL;
Expand Down

0 comments on commit c7d083e

Please sign in to comment.