]> err.no Git - linux-2.6/commitdiff
ext4: Convert bg_block_bitmap to bg_block_bitmap_lo
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Tue, 16 Oct 2007 22:38:25 +0000 (18:38 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 17 Oct 2007 22:50:01 +0000 (18:50 -0400)
Convert bg_block_bitmap to bg_block_bitmap_lo
This helps in catching some BUGS due to direct
partial access of these split fields.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
fs/ext4/super.c
include/linux/ext4_fs.h

index 54450fa1af397954e81b2160cff86a94faf5dd5f..1e8eaaf2d4a5a7b4e00e69582a236aad55b5be60 100644 (file)
@@ -70,9 +70,9 @@ static void ext4_write_super_lockfs(struct super_block *sb);
 ext4_fsblk_t ext4_block_bitmap(struct super_block *sb,
                               struct ext4_group_desc *bg)
 {
-       return le32_to_cpu(bg->bg_block_bitmap) |
+       return le32_to_cpu(bg->bg_block_bitmap_lo) |
                (EXT4_DESC_SIZE(sb) >= EXT4_MIN_DESC_SIZE_64BIT ?
-                (ext4_fsblk_t)le32_to_cpu(bg->bg_block_bitmap_hi) << 32 : 0);
+               (ext4_fsblk_t)le32_to_cpu(bg->bg_block_bitmap_hi) << 32 : 0);
 }
 
 ext4_fsblk_t ext4_inode_bitmap(struct super_block *sb,
@@ -94,7 +94,7 @@ ext4_fsblk_t ext4_inode_table(struct super_block *sb,
 void ext4_block_bitmap_set(struct super_block *sb,
                           struct ext4_group_desc *bg, ext4_fsblk_t blk)
 {
-       bg->bg_block_bitmap = cpu_to_le32((u32)blk);
+       bg->bg_block_bitmap_lo = cpu_to_le32((u32)blk);
        if (EXT4_DESC_SIZE(sb) >= EXT4_MIN_DESC_SIZE_64BIT)
                bg->bg_block_bitmap_hi = cpu_to_le32(blk >> 32);
 }
index 46b304d183454038669eec0f7dab4c9330cc8b48..1dab9847a206734ebc8e64308dd7897211a2d474 100644 (file)
  */
 struct ext4_group_desc
 {
-       __le32  bg_block_bitmap;        /* Blocks bitmap block */
+       __le32  bg_block_bitmap_lo;     /* Blocks bitmap block */
        __le32  bg_inode_bitmap;        /* Inodes bitmap block */
        __le32  bg_inode_table;         /* Inodes table block */
        __le16  bg_free_blocks_count;   /* Free blocks count */