diff options
author | Ingo Molnar <mingo@elte.hu> | 2010-10-07 09:43:11 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-10-07 09:43:11 +0200 |
commit | d4f8f217b8a5d5bd02af979650418dca4caec472 (patch) | |
tree | af047bfa9729c975e24cb7624107574e884d3a57 /mm/compaction.c | |
parent | 2dfbf4dfbe47a484bae20456c12b40763b9b6af7 (diff) | |
parent | 773e3f93577ffb493fb7c39b1a6ecf39b5748e87 (diff) | |
download | op-kernel-dev-d4f8f217b8a5d5bd02af979650418dca4caec472.zip op-kernel-dev-d4f8f217b8a5d5bd02af979650418dca4caec472.tar.gz |
Merge branch 'rcu/urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-2.6-rcu into core/rcu
Diffstat (limited to 'mm/compaction.c')
-rw-r--r-- | mm/compaction.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mm/compaction.c b/mm/compaction.c index 94cce51..4d709ee 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -214,15 +214,16 @@ static void acct_isolated(struct zone *zone, struct compact_control *cc) /* Similar to reclaim, but different enough that they don't share logic */ static bool too_many_isolated(struct zone *zone) { - - unsigned long inactive, isolated; + unsigned long active, inactive, isolated; inactive = zone_page_state(zone, NR_INACTIVE_FILE) + zone_page_state(zone, NR_INACTIVE_ANON); + active = zone_page_state(zone, NR_ACTIVE_FILE) + + zone_page_state(zone, NR_ACTIVE_ANON); isolated = zone_page_state(zone, NR_ISOLATED_FILE) + zone_page_state(zone, NR_ISOLATED_ANON); - return isolated > inactive; + return isolated > (inactive + active) / 2; } /* |