Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 76145
b: refs/heads/master
c: deeeccd
h: refs/heads/master
i:
  76143: d555d49
v: v3
  • Loading branch information
Ingo Molnar committed Jan 25, 2008
1 parent 2d02b50 commit d81b54c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 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: 4df64c0bfb7e0e260d10ebc005f7d0ba1308eed7
refs/heads/master: deeeccd41bd94a9db133d7b923f9a7479a47305d
6 changes: 4 additions & 2 deletions trunk/kernel/sched_rt.c
Original file line number Diff line number Diff line change
Expand Up @@ -762,6 +762,7 @@ move_one_task_rt(struct rq *this_rq, int this_cpu, struct rq *busiest,
/* don't touch RT tasks */
return 0;
}

static void set_cpus_allowed_rt(struct task_struct *p, cpumask_t *new_mask)
{
int weight = cpus_weight(*new_mask);
Expand All @@ -775,9 +776,9 @@ static void set_cpus_allowed_rt(struct task_struct *p, cpumask_t *new_mask)
if (p->se.on_rq && (weight != p->nr_cpus_allowed)) {
struct rq *rq = task_rq(p);

if ((p->nr_cpus_allowed <= 1) && (weight > 1))
if ((p->nr_cpus_allowed <= 1) && (weight > 1)) {
rq->rt.rt_nr_migratory++;
else if((p->nr_cpus_allowed > 1) && (weight <= 1)) {
} else if ((p->nr_cpus_allowed > 1) && (weight <= 1)) {
BUG_ON(!rq->rt.rt_nr_migratory);
rq->rt.rt_nr_migratory--;
}
Expand All @@ -788,6 +789,7 @@ static void set_cpus_allowed_rt(struct task_struct *p, cpumask_t *new_mask)
p->cpus_allowed = *new_mask;
p->nr_cpus_allowed = weight;
}

#else /* CONFIG_SMP */
# define schedule_tail_balance_rt(rq) do { } while (0)
# define schedule_balance_rt(rq, prev) do { } while (0)
Expand Down

0 comments on commit d81b54c

Please sign in to comment.