aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4/super.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-08-17 11:04:47 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-08-17 11:04:47 -0400
commitef824bfba2cce6a75c7cd740f6ad80581e75a109 (patch)
tree10cdb7ae50f4c8a9a16e55a62bce245f1924889f /fs/ext4/super.c
parentd807ff838f48e7778996e577e2a57a5796c32e84 (diff)
parent89a4e48f8479f8145eca9698f39fe188c982212f (diff)
Merge tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4
Pull ext4 bug fixes from Ted Ts'o: "The following are all bug fixes and regressions. The most notable are the ones which cause problems for ext4 on RAID --- a performance problem when mounting very large filesystems, and a kernel OOPS when doing an rm -rf on large directory hierarchies on fast devices." * tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: ext4: fix kernel BUG on large-scale rm -rf commands ext4: fix long mount times on very big file systems ext4: don't call ext4_error while block group is locked ext4: avoid kmemcheck complaint from reading uninitialized memory ext4: make sure the journal sb is written in ext4_clear_journal_err()
Diffstat (limited to 'fs/ext4/super.c')
-rw-r--r--fs/ext4/super.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index 3e0851e4f468..c6e0cb3d1f4a 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -948,6 +948,7 @@ static struct inode *ext4_alloc_inode(struct super_block *sb)
948 ei->i_reserved_meta_blocks = 0; 948 ei->i_reserved_meta_blocks = 0;
949 ei->i_allocated_meta_blocks = 0; 949 ei->i_allocated_meta_blocks = 0;
950 ei->i_da_metadata_calc_len = 0; 950 ei->i_da_metadata_calc_len = 0;
951 ei->i_da_metadata_calc_last_lblock = 0;
951 spin_lock_init(&(ei->i_block_reservation_lock)); 952 spin_lock_init(&(ei->i_block_reservation_lock));
952#ifdef CONFIG_QUOTA 953#ifdef CONFIG_QUOTA
953 ei->i_reserved_quota = 0; 954 ei->i_reserved_quota = 0;
@@ -3108,6 +3109,10 @@ static int count_overhead(struct super_block *sb, ext4_group_t grp,
3108 ext4_group_t i, ngroups = ext4_get_groups_count(sb); 3109 ext4_group_t i, ngroups = ext4_get_groups_count(sb);
3109 int s, j, count = 0; 3110 int s, j, count = 0;
3110 3111
3112 if (!EXT4_HAS_RO_COMPAT_FEATURE(sb, EXT4_FEATURE_RO_COMPAT_BIGALLOC))
3113 return (ext4_bg_has_super(sb, grp) + ext4_bg_num_gdb(sb, grp) +
3114 sbi->s_itb_per_group + 2);
3115
3111 first_block = le32_to_cpu(sbi->s_es->s_first_data_block) + 3116 first_block = le32_to_cpu(sbi->s_es->s_first_data_block) +
3112 (grp * EXT4_BLOCKS_PER_GROUP(sb)); 3117 (grp * EXT4_BLOCKS_PER_GROUP(sb));
3113 last_block = first_block + EXT4_BLOCKS_PER_GROUP(sb) - 1; 3118 last_block = first_block + EXT4_BLOCKS_PER_GROUP(sb) - 1;
@@ -4419,6 +4424,7 @@ static void ext4_clear_journal_err(struct super_block *sb,
4419 ext4_commit_super(sb, 1); 4424 ext4_commit_super(sb, 1);
4420 4425
4421 jbd2_journal_clear_err(journal); 4426 jbd2_journal_clear_err(journal);
4427 jbd2_journal_update_sb_errno(journal);
4422 } 4428 }
4423} 4429}
4424 4430