Lines Matching refs:bg

71 	(struct ext2_block_group *bg, const struct ext_filesystem *fs)  in ext4fs_bg_free_inodes_dec()  argument
73 uint32_t free_inodes = le16_to_cpu(bg->free_inodes); in ext4fs_bg_free_inodes_dec()
75 free_inodes += le16_to_cpu(bg->free_inodes_high) << 16; in ext4fs_bg_free_inodes_dec()
78 bg->free_inodes = cpu_to_le16(free_inodes & 0xffff); in ext4fs_bg_free_inodes_dec()
80 bg->free_inodes_high = cpu_to_le16(free_inodes >> 16); in ext4fs_bg_free_inodes_dec()
84 (struct ext2_block_group *bg, const struct ext_filesystem *fs) in ext4fs_bg_free_blocks_dec() argument
86 uint32_t free_blocks = le16_to_cpu(bg->free_blocks); in ext4fs_bg_free_blocks_dec()
88 free_blocks += le16_to_cpu(bg->free_blocks_high) << 16; in ext4fs_bg_free_blocks_dec()
91 bg->free_blocks = cpu_to_le16(free_blocks & 0xffff); in ext4fs_bg_free_blocks_dec()
93 bg->free_blocks_high = cpu_to_le16(free_blocks >> 16); in ext4fs_bg_free_blocks_dec()
97 (struct ext2_block_group *bg, const struct ext_filesystem *fs) in ext4fs_bg_itable_unused_dec() argument
99 uint32_t free_inodes = le16_to_cpu(bg->bg_itable_unused); in ext4fs_bg_itable_unused_dec()
101 free_inodes += le16_to_cpu(bg->bg_itable_unused_high) << 16; in ext4fs_bg_itable_unused_dec()
104 bg->bg_itable_unused = cpu_to_le16(free_inodes & 0xffff); in ext4fs_bg_itable_unused_dec()
106 bg->bg_itable_unused_high = cpu_to_le16(free_inodes >> 16); in ext4fs_bg_itable_unused_dec()
122 uint32_t ext4fs_bg_get_free_blocks(const struct ext2_block_group *bg, in ext4fs_bg_get_free_blocks() argument
125 uint32_t free_blocks = le16_to_cpu(bg->free_blocks); in ext4fs_bg_get_free_blocks()
127 free_blocks += le16_to_cpu(bg->free_blocks_high) << 16; in ext4fs_bg_get_free_blocks()
132 uint32_t ext4fs_bg_get_free_inodes(const struct ext2_block_group *bg, in ext4fs_bg_get_free_inodes() argument
135 uint32_t free_inodes = le16_to_cpu(bg->free_inodes); in ext4fs_bg_get_free_inodes()
137 free_inodes += le16_to_cpu(bg->free_inodes_high) << 16; in ext4fs_bg_get_free_inodes()
141 static inline uint16_t ext4fs_bg_get_flags(const struct ext2_block_group *bg) in ext4fs_bg_get_flags() argument
143 return le16_to_cpu(bg->bg_flags); in ext4fs_bg_get_flags()
146 static inline void ext4fs_bg_set_flags(struct ext2_block_group *bg, in ext4fs_bg_set_flags() argument
149 bg->bg_flags = cpu_to_le16(flags); in ext4fs_bg_set_flags()
153 uint64_t ext4fs_bg_get_block_id(const struct ext2_block_group *bg, in ext4fs_bg_get_block_id() argument
156 uint64_t block_nr = le32_to_cpu(bg->block_id); in ext4fs_bg_get_block_id()
158 block_nr += (uint64_t)le32_to_cpu(bg->block_id_high) << 32; in ext4fs_bg_get_block_id()
163 uint64_t ext4fs_bg_get_inode_id(const struct ext2_block_group *bg, in ext4fs_bg_get_inode_id() argument
166 uint64_t block_nr = le32_to_cpu(bg->inode_id); in ext4fs_bg_get_inode_id()
168 block_nr += (uint64_t)le32_to_cpu(bg->inode_id_high) << 32; in ext4fs_bg_get_inode_id()
174 uint64_t ext4fs_bg_get_inode_table_id(const struct ext2_block_group *bg, in ext4fs_bg_get_inode_table_id() argument
177 uint64_t block_nr = le32_to_cpu(bg->inode_table_id); in ext4fs_bg_get_inode_table_id()
180 (uint64_t)le32_to_cpu(bg->inode_table_id_high) << 32; in ext4fs_bg_get_inode_table_id()