diff options
Diffstat (limited to 'mm/readahead.c')
-rw-r--r-- | mm/readahead.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/mm/readahead.c b/mm/readahead.c index 23cb61a01c6e..a386f2b6b335 100644 --- a/mm/readahead.c +++ b/mm/readahead.c | |||
@@ -148,13 +148,7 @@ int read_cache_pages(struct address_space *mapping, struct list_head *pages, | |||
148 | if (!pagevec_add(&lru_pvec, page)) | 148 | if (!pagevec_add(&lru_pvec, page)) |
149 | __pagevec_lru_add(&lru_pvec); | 149 | __pagevec_lru_add(&lru_pvec); |
150 | if (ret) { | 150 | if (ret) { |
151 | while (!list_empty(pages)) { | 151 | put_pages_list(pages); |
152 | struct page *victim; | ||
153 | |||
154 | victim = list_to_page(pages); | ||
155 | list_del(&victim->lru); | ||
156 | page_cache_release(victim); | ||
157 | } | ||
158 | break; | 152 | break; |
159 | } | 153 | } |
160 | } | 154 | } |