[PATCH] ext4: switch fsblk to sector_t

Redefine ext3 in-kernel filesystem block type (ext3_fsblk_t) from unsigned
long to sector_t, to allow kernel to handle  >32 bit ext3 blocks.

Signed-off-by: Mingming Cao <cmm@us.ibm.com>
Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Mingming Cao
2006-10-11 01:21:05 -07:00
committed by Linus Torvalds
parent a86c618126
commit 3a5b2ecdd1
6 changed files with 57 additions and 30 deletions

View File

@@ -1433,8 +1433,8 @@ static int ext4_fill_super (struct super_block *sb, void *data, int silent)
* block sizes. We need to calculate the offset from buffer start.
*/
if (blocksize != EXT4_MIN_BLOCK_SIZE) {
logic_sb_block = (sb_block * EXT4_MIN_BLOCK_SIZE) / blocksize;
offset = (sb_block * EXT4_MIN_BLOCK_SIZE) % blocksize;
logic_sb_block = sb_block * EXT4_MIN_BLOCK_SIZE;
offset = sector_div(logic_sb_block, blocksize);
} else {
logic_sb_block = sb_block;
}
@@ -1539,8 +1539,8 @@ static int ext4_fill_super (struct super_block *sb, void *data, int silent)
brelse (bh);
sb_set_blocksize(sb, blocksize);
logic_sb_block = (sb_block * EXT4_MIN_BLOCK_SIZE) / blocksize;
offset = (sb_block * EXT4_MIN_BLOCK_SIZE) % blocksize;
logic_sb_block = sb_block * EXT4_MIN_BLOCK_SIZE;
offset = sector_div(logic_sb_block, blocksize);
bh = sb_bread(sb, logic_sb_block);
if (!bh) {
printk(KERN_ERR