-Index: linux-2.6.5-7.312/fs/ext3/ialloc.c
+Index: linux-2.6.5-7.314/fs/ext3/ialloc.c
===================================================================
---- linux-2.6.5-7.312.orig/fs/ext3/ialloc.c
-+++ linux-2.6.5-7.312/fs/ext3/ialloc.c
+--- linux-2.6.5-7.314.orig/fs/ext3/ialloc.c
++++ linux-2.6.5-7.314/fs/ext3/ialloc.c
@@ -520,12 +520,15 @@ struct inode *ext3_new_inode(handle_t *h
return ERR_PTR(-EPERM);
es = sbi->s_es;
if (goal) {
group = (goal - 1) / EXT3_INODES_PER_GROUP(sb);
-Index: linux-2.6.5-7.312/fs/ext3/super.c
+Index: linux-2.6.5-7.314/fs/ext3/super.c
===================================================================
---- linux-2.6.5-7.312.orig/fs/ext3/super.c
-+++ linux-2.6.5-7.312/fs/ext3/super.c
+--- linux-2.6.5-7.314.orig/fs/ext3/super.c
++++ linux-2.6.5-7.314/fs/ext3/super.c
@@ -37,6 +37,12 @@
#include "acl.h"
#include "group.h"
invalidate_bdev(sbi->journal_bdev, 0);
ext3_blkdev_remove(sbi);
}
-+ remove_proc_entry(EXT3_MAX_DIR_SIZE_NAME, sbi->s_dev_proc);
- remove_proc_entry(sb->s_id, proc_root_ext3);
- sbi->s_dev_proc = NULL;
- sb->s_fs_info = NULL;
-@@ -1251,6 +1258,45 @@ static unsigned long descriptor_loc(stru
++ remove_proc_entry(EXT3_MAX_DIR_SIZE_NAME, sbi->s_dev_proc);
+ if (sbi->s_dev_proc) {
+ remove_proc_entry(sbi->s_dev_proc->name, proc_root_ext3);
+ sbi->s_dev_proc = NULL;
+@@ -1253,6 +1260,45 @@ static unsigned long descriptor_loc(stru
return (first_data_block + has_super + (bg * sbi->s_blocks_per_group));
}
static int ext3_fill_super (struct super_block *sb, void *data, int silent)
{
-@@ -1270,6 +1316,7 @@ static int ext3_fill_super (struct super
+@@ -1273,6 +1319,7 @@ static int ext3_fill_super (struct super
int db_count;
int i;
int needs_recovery;
sbi = kmalloc(sizeof(*sbi), GFP_KERNEL);
if (!sbi)
-@@ -1287,6 +1334,23 @@ static int ext3_fill_super (struct super
- return -ENOMEM;
+@@ -1299,6 +1346,23 @@ static int ext3_fill_super (struct super
+ sb->s_id);
}
+ sbi->s_max_dir_size = EXT3_DEFAULT_MAX_DIR_SIZE;
blocksize = sb_min_blocksize(sb, EXT3_MIN_BLOCK_SIZE);
if (!blocksize) {
printk(KERN_ERR "EXT3-fs: unable to set blocksize\n");
-@@ -1701,6 +1765,7 @@ failed_mount:
+@@ -1713,6 +1777,7 @@ failed_mount:
ext3_blkdev_remove(sbi);
brelse(bh);
out_fail:
+ remove_proc_entry(EXT3_MAX_DIR_SIZE_NAME, sbi->s_dev_proc);
- remove_proc_entry(sb->s_id, proc_root_ext3);
- sbi->s_dev_proc = NULL;
- sb->s_fs_info = NULL;
-Index: linux-2.6.5-7.312/include/linux/ext3_fs_sb.h
+ if (sbi->s_dev_proc) {
+ remove_proc_entry(sbi->s_dev_proc->name, proc_root_ext3);
+ sbi->s_dev_proc = NULL;
+Index: linux-2.6.5-7.314/include/linux/ext3_fs_sb.h
===================================================================
---- linux-2.6.5-7.312.orig/include/linux/ext3_fs_sb.h
-+++ linux-2.6.5-7.312/include/linux/ext3_fs_sb.h
+--- linux-2.6.5-7.314.orig/include/linux/ext3_fs_sb.h
++++ linux-2.6.5-7.314/include/linux/ext3_fs_sb.h
@@ -119,6 +119,8 @@ struct ext3_sb_info {
unsigned long s_mb_last_group;
unsigned long s_mb_last_start;