[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:
committed by
Linus Torvalds
parent
a86c618126
commit
3a5b2ecdd1
@@ -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
|
||||
|
Reference in New Issue
Block a user