Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 135723
b: refs/heads/master
c: a021dc0
h: refs/heads/master
i:
  135721: b673c94
  135719: 0bf930b
v: v3
  • Loading branch information
Gautham R Shenoy authored and Ingo Molnar committed Mar 25, 2009
1 parent 4ac1bd3 commit fc71747
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 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: dbc523a3b86f9e1765b5e70e6886913b99cc5cec
refs/heads/master: a021dc03376707c55a3483e32c16b8986d4414cc
23 changes: 14 additions & 9 deletions trunk/kernel/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -3386,8 +3386,17 @@ static inline void update_sd_lb_stats(struct sched_domain *sd, int this_cpu,
int load_idx;

#if defined(CONFIG_SCHED_MC) || defined(CONFIG_SCHED_SMT)
sds->power_savings_balance = 1;
sds->min_nr_running = ULONG_MAX;
/*
* Busy processors will not participate in power savings
* balance.
*/
if (idle == CPU_NOT_IDLE || !(sd->flags & SD_POWERSAVINGS_BALANCE))
sds->power_savings_balance = 0;
else {
sds->power_savings_balance = 1;
sds->min_nr_running = ULONG_MAX;
sds->leader_nr_running = 0;
}
#endif
load_idx = get_sd_load_idx(sd, idle);

Expand Down Expand Up @@ -3422,12 +3431,8 @@ static inline void update_sd_lb_stats(struct sched_domain *sd, int this_cpu,
}

#if defined(CONFIG_SCHED_MC) || defined(CONFIG_SCHED_SMT)
/*
* Busy processors will not participate in power savings
* balance.
*/
if (idle == CPU_NOT_IDLE ||
!(sd->flags & SD_POWERSAVINGS_BALANCE))

if (!sds->power_savings_balance)
goto group_next;

/*
Expand Down Expand Up @@ -3651,7 +3656,7 @@ find_busiest_group(struct sched_domain *sd, int this_cpu,

out_balanced:
#if defined(CONFIG_SCHED_MC) || defined(CONFIG_SCHED_SMT)
if (idle == CPU_NOT_IDLE || !(sd->flags & SD_POWERSAVINGS_BALANCE))
if (!sds.power_savings_balance)
goto ret;

if (sds.this != sds.group_leader || sds.group_leader == sds.group_min)
Expand Down

0 comments on commit fc71747

Please sign in to comment.