Commit:     6c57c2c8d3862c8d5b908669654f6565da74ec19
Parent:     d4c3d19d0c10701459f16c022ea23eff5e127747
Author:     Jeff Mahoney <[EMAIL PROTECTED]>
AuthorDate: Thu Oct 18 23:39:25 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Fri Oct 19 11:53:35 2007 -0700

    reiserfs: fix memset byte count during resize
    Correct the memset in reiserfs_resize to clear the memory allocated for the
    new bitmap info structs.  Previously, it would clear the memory used by the
    old size.  Depending on the contents of memory, this could cause incorrect
    caching behavior for bitmap blocks in the newly allocated area.
    Signed-off-by: Jeff Mahoney <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
 fs/reiserfs/resize.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/reiserfs/resize.c b/fs/reiserfs/resize.c
index 976cc78..3bec2f9 100644
--- a/fs/reiserfs/resize.c
+++ b/fs/reiserfs/resize.c
@@ -119,7 +119,7 @@ int reiserfs_resize(struct super_block *s, unsigned long 
                        return -ENOMEM;
                memset(bitmap, 0,
-                      sizeof(struct reiserfs_bitmap_info) * SB_BMAP_NR(s));
+                      sizeof(struct reiserfs_bitmap_info) * bmap_nr_new);
                for (i = 0; i < bmap_nr; i++)
                        bitmap[i] = old_bitmap[i];
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at

Reply via email to