diff options
author | Hugh Dickins <hugh@veritas.com> | 2009-01-06 14:39:24 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-06 15:59:02 -0800 |
commit | 6d91add09f4bad5f4d4233b13faa392f0c4b16be (patch) | |
tree | 26f77047b316dfc0879307fbfda84b15a199155f /mm/migrate.c | |
parent | 3c1d43787b48c798f44dc32a6e6deb5ca2da3e68 (diff) | |
download | linux-3.10-6d91add09f4bad5f4d4233b13faa392f0c4b16be.tar.gz linux-3.10-6d91add09f4bad5f4d4233b13faa392f0c4b16be.tar.bz2 linux-3.10-6d91add09f4bad5f4d4233b13faa392f0c4b16be.zip |
mm: add Set,ClearPageSwapCache stubs
If we add NOOP stubs for SetPageSwapCache() and ClearPageSwapCache(), then
we can remove the #ifdef CONFIG_SWAPs from mm/migrate.c.
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Acked-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Cc: Mel Gorman <mel@csn.ul.ie>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/migrate.c')
-rw-r--r-- | mm/migrate.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/mm/migrate.c b/mm/migrate.c index 60510306c44..55373983c9c 100644 --- a/mm/migrate.c +++ b/mm/migrate.c @@ -300,12 +300,10 @@ static int migrate_page_move_mapping(struct address_space *mapping, * Now we know that no one else is looking at the page. */ get_page(newpage); /* add cache reference */ -#ifdef CONFIG_SWAP if (PageSwapCache(page)) { SetPageSwapCache(newpage); set_page_private(newpage, page_private(page)); } -#endif radix_tree_replace_slot(pslot, newpage); @@ -373,9 +371,7 @@ static void migrate_page_copy(struct page *newpage, struct page *page) mlock_migrate_page(newpage, page); -#ifdef CONFIG_SWAP ClearPageSwapCache(page); -#endif ClearPagePrivate(page); set_page_private(page, 0); /* page->mapping contains a flag for PageAnon() */ |