Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 145705
b: refs/heads/master
c: e790fb0
h: refs/heads/master
i:
  145703: adc6ccc
v: v3
  • Loading branch information
Gautham R Shenoy authored and Ingo Molnar committed Apr 14, 2009
1 parent 9e56977 commit 2bc0b27
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 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: f711f6090a81cbd396b63de90f415d33f563af9b
refs/heads/master: e790fb0ba64bfec158e1219d899cb588275d12ab
18 changes: 17 additions & 1 deletion trunk/kernel/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -4414,8 +4414,24 @@ int select_nohz_load_balancer(int stop_tick)
/* make me the ilb owner */
if (atomic_cmpxchg(&nohz.load_balancer, -1, cpu) == -1)
return 1;
} else if (atomic_read(&nohz.load_balancer) == cpu)
} else if (atomic_read(&nohz.load_balancer) == cpu) {
int new_ilb;

if (!(sched_smt_power_savings ||
sched_mc_power_savings))
return 1;
/*
* Check to see if there is a more power-efficient
* ilb.
*/
new_ilb = find_new_ilb(cpu);
if (new_ilb < nr_cpu_ids && new_ilb != cpu) {
atomic_set(&nohz.load_balancer, -1);
resched_cpu(new_ilb);
return 0;
}
return 1;
}
} else {
if (!cpumask_test_cpu(cpu, nohz.cpu_mask))
return 0;
Expand Down

0 comments on commit 2bc0b27

Please sign in to comment.