diff options
author | Hugh Dickins <hughd@google.com> | 2012-01-10 18:08:33 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-01-10 19:30:46 -0500 |
commit | 043bcbe5ec51e0478ef2b44acef17193e01d7f70 (patch) | |
tree | 4b93556acfdd790ea3e85ed60240134bd06c0d1b /mm | |
parent | faed836a2371a96901057f310e436a09eded94fd (diff) |
mm: test PageSwapBacked in lumpy reclaim
Lumpy reclaim does well to stop at a PageAnon when there's no swap, but
better is to stop at any PageSwapBacked, which includes shmem/tmpfs too.
Signed-off-by: Hugh Dickins <hughd@google.com>
Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Reviewed-by: Minchan Kim <minchan@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/vmscan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c index b935e6f0d695..8a4e767fb8ac 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c | |||
@@ -1166,7 +1166,7 @@ static unsigned long isolate_lru_pages(unsigned long nr_to_scan, | |||
1166 | * anon page which don't already have a swap slot is | 1166 | * anon page which don't already have a swap slot is |
1167 | * pointless. | 1167 | * pointless. |
1168 | */ | 1168 | */ |
1169 | if (nr_swap_pages <= 0 && PageAnon(cursor_page) && | 1169 | if (nr_swap_pages <= 0 && PageSwapBacked(cursor_page) && |
1170 | !PageSwapCache(cursor_page)) | 1170 | !PageSwapCache(cursor_page)) |
1171 | break; | 1171 | break; |
1172 | 1172 | ||