diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/ext4_fs.h | 11 | ||||
-rw-r--r-- | include/linux/ext4_fs_i.h | 5 | ||||
-rw-r--r-- | include/linux/ext4_fs_sb.h | 2 |
3 files changed, 11 insertions, 7 deletions
diff --git a/include/linux/ext4_fs.h b/include/linux/ext4_fs.h index 5e2da0974d16..e1103c2a0d42 100644 --- a/include/linux/ext4_fs.h +++ b/include/linux/ext4_fs.h | |||
@@ -830,7 +830,7 @@ struct ext4_iloc | |||
830 | { | 830 | { |
831 | struct buffer_head *bh; | 831 | struct buffer_head *bh; |
832 | unsigned long offset; | 832 | unsigned long offset; |
833 | unsigned long block_group; | 833 | ext4_group_t block_group; |
834 | }; | 834 | }; |
835 | 835 | ||
836 | static inline struct ext4_inode *ext4_raw_inode(struct ext4_iloc *iloc) | 836 | static inline struct ext4_inode *ext4_raw_inode(struct ext4_iloc *iloc) |
@@ -855,7 +855,7 @@ struct dir_private_info { | |||
855 | 855 | ||
856 | /* calculate the first block number of the group */ | 856 | /* calculate the first block number of the group */ |
857 | static inline ext4_fsblk_t | 857 | static inline ext4_fsblk_t |
858 | ext4_group_first_block_no(struct super_block *sb, unsigned long group_no) | 858 | ext4_group_first_block_no(struct super_block *sb, ext4_group_t group_no) |
859 | { | 859 | { |
860 | return group_no * (ext4_fsblk_t)EXT4_BLOCKS_PER_GROUP(sb) + | 860 | return group_no * (ext4_fsblk_t)EXT4_BLOCKS_PER_GROUP(sb) + |
861 | le32_to_cpu(EXT4_SB(sb)->s_es->s_first_data_block); | 861 | le32_to_cpu(EXT4_SB(sb)->s_es->s_first_data_block); |
@@ -886,8 +886,9 @@ extern unsigned int ext4_block_group(struct super_block *sb, | |||
886 | ext4_fsblk_t blocknr); | 886 | ext4_fsblk_t blocknr); |
887 | extern ext4_grpblk_t ext4_block_group_offset(struct super_block *sb, | 887 | extern ext4_grpblk_t ext4_block_group_offset(struct super_block *sb, |
888 | ext4_fsblk_t blocknr); | 888 | ext4_fsblk_t blocknr); |
889 | extern int ext4_bg_has_super(struct super_block *sb, int group); | 889 | extern int ext4_bg_has_super(struct super_block *sb, ext4_group_t group); |
890 | extern unsigned long ext4_bg_num_gdb(struct super_block *sb, int group); | 890 | extern unsigned long ext4_bg_num_gdb(struct super_block *sb, |
891 | ext4_group_t group); | ||
891 | extern ext4_fsblk_t ext4_new_block (handle_t *handle, struct inode *inode, | 892 | extern ext4_fsblk_t ext4_new_block (handle_t *handle, struct inode *inode, |
892 | ext4_fsblk_t goal, int *errp); | 893 | ext4_fsblk_t goal, int *errp); |
893 | extern ext4_fsblk_t ext4_new_blocks (handle_t *handle, struct inode *inode, | 894 | extern ext4_fsblk_t ext4_new_blocks (handle_t *handle, struct inode *inode, |
@@ -900,7 +901,7 @@ extern void ext4_free_blocks_sb (handle_t *handle, struct super_block *sb, | |||
900 | extern ext4_fsblk_t ext4_count_free_blocks (struct super_block *); | 901 | extern ext4_fsblk_t ext4_count_free_blocks (struct super_block *); |
901 | extern void ext4_check_blocks_bitmap (struct super_block *); | 902 | extern void ext4_check_blocks_bitmap (struct super_block *); |
902 | extern struct ext4_group_desc * ext4_get_group_desc(struct super_block * sb, | 903 | extern struct ext4_group_desc * ext4_get_group_desc(struct super_block * sb, |
903 | unsigned int block_group, | 904 | ext4_group_t block_group, |
904 | struct buffer_head ** bh); | 905 | struct buffer_head ** bh); |
905 | extern int ext4_should_retry_alloc(struct super_block *sb, int *retries); | 906 | extern int ext4_should_retry_alloc(struct super_block *sb, int *retries); |
906 | extern void ext4_init_block_alloc_info(struct inode *); | 907 | extern void ext4_init_block_alloc_info(struct inode *); |
diff --git a/include/linux/ext4_fs_i.h b/include/linux/ext4_fs_i.h index 6c610b67b047..2b4e3700c725 100644 --- a/include/linux/ext4_fs_i.h +++ b/include/linux/ext4_fs_i.h | |||
@@ -30,6 +30,9 @@ typedef unsigned long long ext4_fsblk_t; | |||
30 | /* data type for file logical block number */ | 30 | /* data type for file logical block number */ |
31 | typedef __u32 ext4_lblk_t; | 31 | typedef __u32 ext4_lblk_t; |
32 | 32 | ||
33 | /* data type for block group number */ | ||
34 | typedef unsigned long ext4_group_t; | ||
35 | |||
33 | struct ext4_reserve_window { | 36 | struct ext4_reserve_window { |
34 | ext4_fsblk_t _rsv_start; /* First byte reserved */ | 37 | ext4_fsblk_t _rsv_start; /* First byte reserved */ |
35 | ext4_fsblk_t _rsv_end; /* Last byte reserved or 0 */ | 38 | ext4_fsblk_t _rsv_end; /* Last byte reserved or 0 */ |
@@ -92,7 +95,7 @@ struct ext4_inode_info { | |||
92 | * place a file's data blocks near its inode block, and new inodes | 95 | * place a file's data blocks near its inode block, and new inodes |
93 | * near to their parent directory's inode. | 96 | * near to their parent directory's inode. |
94 | */ | 97 | */ |
95 | __u32 i_block_group; | 98 | ext4_group_t i_block_group; |
96 | __u32 i_state; /* Dynamic state flags for ext4 */ | 99 | __u32 i_state; /* Dynamic state flags for ext4 */ |
97 | 100 | ||
98 | /* block reservation info */ | 101 | /* block reservation info */ |
diff --git a/include/linux/ext4_fs_sb.h b/include/linux/ext4_fs_sb.h index b40e827cd495..f15821c5e4c4 100644 --- a/include/linux/ext4_fs_sb.h +++ b/include/linux/ext4_fs_sb.h | |||
@@ -35,7 +35,7 @@ struct ext4_sb_info { | |||
35 | unsigned long s_itb_per_group; /* Number of inode table blocks per group */ | 35 | unsigned long s_itb_per_group; /* Number of inode table blocks per group */ |
36 | unsigned long s_gdb_count; /* Number of group descriptor blocks */ | 36 | unsigned long s_gdb_count; /* Number of group descriptor blocks */ |
37 | unsigned long s_desc_per_block; /* Number of group descriptors per block */ | 37 | unsigned long s_desc_per_block; /* Number of group descriptors per block */ |
38 | unsigned long s_groups_count; /* Number of groups in the fs */ | 38 | ext4_group_t s_groups_count; /* Number of groups in the fs */ |
39 | unsigned long s_overhead_last; /* Last calculated overhead */ | 39 | unsigned long s_overhead_last; /* Last calculated overhead */ |
40 | unsigned long s_blocks_last; /* Last seen block count */ | 40 | unsigned long s_blocks_last; /* Last seen block count */ |
41 | struct buffer_head * s_sbh; /* Buffer containing the super block */ | 41 | struct buffer_head * s_sbh; /* Buffer containing the super block */ |