3.0-stable review patch.  If anyone has any objections, please let me know.

------------------

From: Eric Sandeen <sand...@redhat.com>

commit 66bea92c69477a75a5d37b9bfed5773c92a3c4b4 upstream.

ext4_da_block_invalidatepages is missing a pagevec_init(),
which means that pvec->cold contains random garbage.

This affects whether the page goes to the front or
back of the LRU when ->cold makes it to
free_hot_cold_page()

Reviewed-by: Lukas Czerner <lczer...@redhat.com>
Reviewed-by: Carlos Maiolino <cmaiol...@redhat.com>
Signed-off-by: Eric Sandeen <sand...@redhat.com>
Signed-off-by: "Theodore Ts'o" <ty...@mit.edu>
Signed-off-by: CAI Qian <caiq...@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gre...@linuxfoundation.org>

---
 fs/ext4/inode.c |    2 ++
 1 file changed, 2 insertions(+)

--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -2199,6 +2199,8 @@ static void ext4_da_block_invalidatepage
 
        index = mpd->first_page;
        end   = mpd->next_page - 1;
+
+       pagevec_init(&pvec, 0);
        while (index <= end) {
                nr_pages = pagevec_lookup(&pvec, mapping, index, PAGEVEC_SIZE);
                if (nr_pages == 0)


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to