aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4/resize.c
diff options
context:
space:
mode:
authorMarcin Slusarz <marcin.slusarz@gmail.com>2008-04-17 10:38:59 -0400
committerTheodore Ts'o <tytso@mit.edu>2008-04-17 10:38:59 -0400
commite8546d0615542684ca02ba03edebec1a503beb6b (patch)
treec0114f0e86278dd1418f5a548b38d5d1c4b157b3 /fs/ext4/resize.c
parent9a0762c5af40e4aa64fef999967459c98e6ae4c9 (diff)
ext4: le*_add_cpu conversion
replace all: little_endian_variable = cpu_to_leX(leX_to_cpu(little_endian_variable) + expression_in_cpu_byteorder); with: leX_add_cpu(&little_endian_variable, expression_in_cpu_byteorder); generated with semantic patch Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Cc: linux-ext4@vger.kernel.org Cc: sct@redhat.com Cc: Andrew Morton <akpm@linux-foundation.org> Cc: adilger@clusterfs.com Cc: Mingming Cao <cmm@us.ibm.com>
Diffstat (limited to 'fs/ext4/resize.c')
-rw-r--r--fs/ext4/resize.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/ext4/resize.c b/fs/ext4/resize.c
index e29efa0f9d62..728e3efa84b5 100644
--- a/fs/ext4/resize.c
+++ b/fs/ext4/resize.c
@@ -502,8 +502,7 @@ static int add_new_gdb(handle_t *handle, struct inode *inode,
502 EXT4_SB(sb)->s_gdb_count++; 502 EXT4_SB(sb)->s_gdb_count++;
503 kfree(o_group_desc); 503 kfree(o_group_desc);
504 504
505 es->s_reserved_gdt_blocks = 505 le16_add_cpu(&es->s_reserved_gdt_blocks, -1);
506 cpu_to_le16(le16_to_cpu(es->s_reserved_gdt_blocks) - 1);
507 ext4_journal_dirty_metadata(handle, EXT4_SB(sb)->s_sbh); 506 ext4_journal_dirty_metadata(handle, EXT4_SB(sb)->s_sbh);
508 507
509 return 0; 508 return 0;
@@ -877,8 +876,7 @@ int ext4_group_add(struct super_block *sb, struct ext4_new_group_data *input)
877 */ 876 */
878 ext4_blocks_count_set(es, ext4_blocks_count(es) + 877 ext4_blocks_count_set(es, ext4_blocks_count(es) +
879 input->blocks_count); 878 input->blocks_count);
880 es->s_inodes_count = cpu_to_le32(le32_to_cpu(es->s_inodes_count) + 879 le32_add_cpu(&es->s_inodes_count, EXT4_INODES_PER_GROUP(sb));
881 EXT4_INODES_PER_GROUP(sb));
882 880
883 /* 881 /*
884 * We need to protect s_groups_count against other CPUs seeing 882 * We need to protect s_groups_count against other CPUs seeing