diff options
author | Minchan Kim <minchan.kim@gmail.com> | 2010-05-24 17:31:59 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-25 11:06:57 -0400 |
commit | e13861d822f8f443ca0c020ea8fc2dc01039cd63 (patch) | |
tree | 0e1ccaa6a2d682f7636b9d5ef5d4c73a28074988 /mm | |
parent | 4b50dc26a0a25a9d1998d206e1f7d849aa78063f (diff) |
mm: remove return value of putback_lru_pages()
putback_lru_page() never can fail. So it doesn't matter count of "the
number of pages put back".
In addition, users of this functions don't use return value.
Let's remove unnecessary code.
Signed-off-by: Minchan Kim <minchan.kim@gmail.com>
Reviewed-by: Rik van Riel <riel@redhat.com>
Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
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/migrate.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/mm/migrate.c b/mm/migrate.c index d3f3f7f81075..5938db54e1d7 100644 --- a/mm/migrate.c +++ b/mm/migrate.c | |||
@@ -58,23 +58,18 @@ int migrate_prep(void) | |||
58 | /* | 58 | /* |
59 | * Add isolated pages on the list back to the LRU under page lock | 59 | * Add isolated pages on the list back to the LRU under page lock |
60 | * to avoid leaking evictable pages back onto unevictable list. | 60 | * to avoid leaking evictable pages back onto unevictable list. |
61 | * | ||
62 | * returns the number of pages put back. | ||
63 | */ | 61 | */ |
64 | int putback_lru_pages(struct list_head *l) | 62 | void putback_lru_pages(struct list_head *l) |
65 | { | 63 | { |
66 | struct page *page; | 64 | struct page *page; |
67 | struct page *page2; | 65 | struct page *page2; |
68 | int count = 0; | ||
69 | 66 | ||
70 | list_for_each_entry_safe(page, page2, l, lru) { | 67 | list_for_each_entry_safe(page, page2, l, lru) { |
71 | list_del(&page->lru); | 68 | list_del(&page->lru); |
72 | dec_zone_page_state(page, NR_ISOLATED_ANON + | 69 | dec_zone_page_state(page, NR_ISOLATED_ANON + |
73 | page_is_file_cache(page)); | 70 | page_is_file_cache(page)); |
74 | putback_lru_page(page); | 71 | putback_lru_page(page); |
75 | count++; | ||
76 | } | 72 | } |
77 | return count; | ||
78 | } | 73 | } |
79 | 74 | ||
80 | /* | 75 | /* |