summaryrefslogtreecommitdiffstats
path: root/fs/ext4/resize.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-06-06 15:30:53 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-06-06 15:30:53 -0700
commit5f0e62c3e1db9acb35b750e02cddc1fcb8cfd52b (patch)
tree2c0b507ed89a97116cc595e090ebaeb1439df865 /fs/ext4/resize.c
parentaab2545fdd6641b76af0ae96456c4ca9d1e50dad (diff)
parent571640cad3fda6475da45d91cf86076f1f86bd9b (diff)
downloadtalos-obmc-linux-5f0e62c3e1db9acb35b750e02cddc1fcb8cfd52b.tar.gz
talos-obmc-linux-5f0e62c3e1db9acb35b750e02cddc1fcb8cfd52b.zip
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: ext4: enable barriers by default jbd2: Fix barrier fallback code to re-lock the buffer head ext4: Display the journal_async_commit mount option in /proc/mounts jbd2: If a journal checksum error is detected, propagate the error to ext4 jbd2: Fix memory leak when verifying checksums in the journal ext4: fix online resize bug ext4: Fix uninit block group initialization with FLEX_BG ext4: Fix use of uninitialized data with debug enabled.
Diffstat (limited to 'fs/ext4/resize.c')
-rw-r--r--fs/ext4/resize.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ext4/resize.c b/fs/ext4/resize.c
index 9f086a6a472b..9ecb92f68543 100644
--- a/fs/ext4/resize.c
+++ b/fs/ext4/resize.c
@@ -563,7 +563,8 @@ static int reserve_backup_gdb(handle_t *handle, struct inode *inode,
}
blk = EXT4_SB(sb)->s_sbh->b_blocknr + 1 + EXT4_SB(sb)->s_gdb_count;
- data = (__le32 *)dind->b_data + EXT4_SB(sb)->s_gdb_count;
+ data = (__le32 *)dind->b_data + (EXT4_SB(sb)->s_gdb_count %
+ EXT4_ADDR_PER_BLOCK(sb));
end = (__le32 *)dind->b_data + EXT4_ADDR_PER_BLOCK(sb);
/* Get each reserved primary GDT block and verify it holds backups */
OpenPOWER on IntegriCloud