[<prev] [next>] [day] [month] [year] [list]
Message-ID: <873b97und6.fsf@duaron.myhome.or.jp>
Date: Mon, 30 Oct 2006 00:56:37 +0900
From: OGAWA Hirofumi <hirofumi@...l.parknet.co.jp>
To: Andrew Morton <akpm@...l.org>
Cc: linux-kernel@...r.kernel.org
Subject: [PATCH] read_cache_pages() cleanup
This uses put_pages_list() instead of opencoded one.
Signed-off-by: OGAWA Hirofumi <hirofumi@...l.parknet.co.jp>
---
mm/readahead.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff -puN mm/readahead.c~read_cache_pages-cleanup mm/readahead.c
--- linux-2.6/mm/readahead.c~read_cache_pages-cleanup 2006-10-30 00:12:20.000000000 +0900
+++ linux-2.6-hirofumi/mm/readahead.c 2006-10-30 00:12:20.000000000 +0900
@@ -148,13 +148,7 @@ int read_cache_pages(struct address_spac
if (!pagevec_add(&lru_pvec, page))
__pagevec_lru_add(&lru_pvec);
if (ret) {
- while (!list_empty(pages)) {
- struct page *victim;
-
- victim = list_to_page(pages);
- list_del(&victim->lru);
- page_cache_release(victim);
- }
+ put_pages_list(pages);
break;
}
}
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists