-Index: linux-2.6.18-92.1.17/fs/ext3/super.c
+Index: linux-2.6.18-92.1.22/fs/ext3/super.c
===================================================================
---- linux-2.6.18-92.1.17.orig/fs/ext3/super.c
-+++ linux-2.6.18-92.1.17/fs/ext3/super.c
+--- linux-2.6.18-92.1.22.orig/fs/ext3/super.c
++++ linux-2.6.18-92.1.22/fs/ext3/super.c
@@ -35,6 +35,8 @@
#include <linux/namei.h>
#include <linux/quotaops.h>
if (sbi->s_dev_proc) {
remove_proc_entry(sbi->s_dev_proc->name, proc_root_ext3);
sbi->s_dev_proc = NULL;
-@@ -1543,6 +1547,313 @@ static ext3_fsblk_t descriptor_loc(struc
+@@ -1543,6 +1547,329 @@ static ext3_fsblk_t descriptor_loc(struc
return (has_super + ext3_group_first_block_no(sb, bg));
}
+ if (*bh)
+ clear_buffer_uptodate(*bh);
+
++#if 0
+ brelse(*bh);
+
+ *bh = sb_bread(sb, mmp_block);
++#else
++ if (!*bh)
++ *bh = sb_getblk(sb, mmp_block);
++ if (*bh) {
++ get_bh(*bh);
++ lock_buffer(*bh);
++ (*bh)->b_end_io = end_buffer_read_sync;
++ submit_bh(READ_SYNC, *bh);
++ wait_on_buffer(*bh);
++ if (!buffer_uptodate(*bh)) {
++ brelse(*bh);
++ *bh = NULL;
++ }
++ }
++#endif
+ if (!*bh) {
+ ext3_warning(sb, __FUNCTION__,
+ "Error while reading MMP block %lu", mmp_block);
static int ext3_fill_super (struct super_block *sb, void *data, int silent)
{
-@@ -1875,6 +2186,11 @@ static int ext3_fill_super (struct super
+@@ -1875,6 +2202,11 @@ static int ext3_fill_super (struct super
EXT3_HAS_INCOMPAT_FEATURE(sb,
EXT3_FEATURE_INCOMPAT_RECOVER));
/*
* The first inode we look at is the journal inode. Don't try
* root first: it may be modified in the journal!
-@@ -2007,6 +2323,8 @@ cantfind_ext3:
+@@ -2007,6 +2339,8 @@ cantfind_ext3:
failed_mount4:
journal_destroy(sbi->s_journal);
failed_mount3:
percpu_counter_destroy(&sbi->s_freeblocks_counter);
percpu_counter_destroy(&sbi->s_freeinodes_counter);
percpu_counter_destroy(&sbi->s_dirs_counter);
-@@ -2482,7 +2800,7 @@ static int ext3_remount (struct super_bl
+@@ -2482,7 +2816,7 @@ static int ext3_remount (struct super_bl
ext3_fsblk_t n_blocks_count = 0;
unsigned long old_sb_flags;
struct ext3_mount_options old_opts;
#ifdef CONFIG_QUOTA
int i;
#endif
-@@ -2580,6 +2898,11 @@ static int ext3_remount (struct super_bl
+@@ -2580,6 +2914,11 @@ static int ext3_remount (struct super_bl
}
if (!ext3_setup_super (sb, es, 0))
sb->s_flags &= ~MS_RDONLY;
}
}
#ifdef CONFIG_QUOTA
-Index: linux-2.6.18-92.1.17/include/linux/ext3_fs.h
+Index: linux-2.6.18-92.1.22/include/linux/ext3_fs.h
===================================================================
---- linux-2.6.18-92.1.17.orig/include/linux/ext3_fs.h
-+++ linux-2.6.18-92.1.17/include/linux/ext3_fs.h
+--- linux-2.6.18-92.1.22.orig/include/linux/ext3_fs.h
++++ linux-2.6.18-92.1.22/include/linux/ext3_fs.h
@@ -594,13 +594,17 @@ struct ext3_super_block {
__le32 s_first_meta_bg; /* First metablock block group */
__le32 s_mkfs_time; /* When the filesystem was created */
* Function prototypes
*/
-Index: linux-2.6.18-92.1.17/include/linux/ext3_fs_sb.h
+Index: linux-2.6.18-92.1.22/include/linux/ext3_fs_sb.h
===================================================================
---- linux-2.6.18-92.1.17.orig/include/linux/ext3_fs_sb.h
-+++ linux-2.6.18-92.1.17/include/linux/ext3_fs_sb.h
+--- linux-2.6.18-92.1.22.orig/include/linux/ext3_fs_sb.h
++++ linux-2.6.18-92.1.22/include/linux/ext3_fs_sb.h
@@ -158,6 +158,7 @@ struct ext3_sb_info {
/* locality groups */
struct ext3_locality_group *s_locality_groups;