Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 115859
b: refs/heads/master
c: e0f79b8
h: refs/heads/master
i:
  115857: 2ba4f57
  115855: caddaf0
v: v3
  • Loading branch information
Johannes Weiner authored and Linus Torvalds committed Oct 20, 2008
1 parent 975e6d9 commit fecc202
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 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: 902d2e8ae0de29f483840ba1134af27343b9564d
refs/heads/master: e0f79b8f1f3394bb344b7b83d6f121ac2af327de
7 changes: 2 additions & 5 deletions trunk/mm/vmscan.c
Original file line number Diff line number Diff line change
Expand Up @@ -1413,16 +1413,13 @@ static unsigned long shrink_zone(int priority, struct zone *zone,
if (scan_global_lru(sc)) {
int file = is_file_lru(l);
int scan;
/*
* Add one to nr_to_scan just to make sure that the
* kernel will slowly sift through each list.
*/

scan = zone_page_state(zone, NR_LRU_BASE + l);
if (priority) {
scan >>= priority;
scan = (scan * percent[file]) / 100;
}
zone->lru[l].nr_scan += scan + 1;
zone->lru[l].nr_scan += scan;
nr[l] = zone->lru[l].nr_scan;
if (nr[l] >= sc->swap_cluster_max)
zone->lru[l].nr_scan = 0;
Expand Down

0 comments on commit fecc202

Please sign in to comment.