summaryrefslogtreecommitdiff
path: root/fs/ext4/super.c
diff options
context:
space:
mode:
authorAndreas Dilger <adilger@dilger.ca>2019-02-14 17:52:18 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-05-22 07:37:46 +0200
commite8816d3bc5956a3d4d0f00651138a8a3b36a07bf (patch)
tree09378abfc114e6fcb38586dbe7557b24f0eade28 /fs/ext4/super.c
parent6172ae55a187378b091282c7a5b4895635e63371 (diff)
ext4: don't update s_rev_level if not required
commit c9e716eb9b3455a83ed7c5f5a81256a3da779a95 upstream. Don't update the superblock s_rev_level during mount if it isn't actually necessary, only if superblock features are being set by the kernel. This was originally added for ext3 since it always set the INCOMPAT_RECOVER and HAS_JOURNAL features during mount, but this is not needed since no journal mode was added to ext4. That will allow Geert to mount his 20-year-old ext2 rev 0.0 m68k filesystem, as a testament of the backward compatibility of ext4. Fixes: 0390131ba84f ("ext4: Allow ext4 to run without a journal") Signed-off-by: Andreas Dilger <adilger@dilger.ca> Signed-off-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/ext4/super.c')
-rw-r--r--fs/ext4/super.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index 07d73fb22b60..a270391228af 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -2259,7 +2259,6 @@ static int ext4_setup_super(struct super_block *sb, struct ext4_super_block *es,
es->s_max_mnt_count = cpu_to_le16(EXT4_DFL_MAX_MNT_COUNT);
le16_add_cpu(&es->s_mnt_count, 1);
ext4_update_tstamp(es, s_mtime);
- ext4_update_dynamic_rev(sb);
if (sbi->s_journal)
ext4_set_feature_journal_needs_recovery(sb);