[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200608091223.04492.rjw@sisk.pl>
Date: Wed, 9 Aug 2006 12:23:04 +0200
From: "Rafael J. Wysocki" <rjw@...k.pl>
To: David Howells <dhowells@...hat.com>
Cc: torvalds@...l.org, akpm@...l.org, linux-kernel@...r.kernel.org,
reiserfs-dev@...esys.com, Olof Johansson <olof@...om.net>
Subject: Re: [PATCH] ReiserFS: Make sure all dentries refs are released before calling kill_block_super()
On Wednesday 09 August 2006 12:14, David Howells wrote:
> Rafael J. Wysocki <rjw@...k.pl> wrote:
>
> > It didn't apply cleanly to -rc3-mm2 for me and produces the appended oops
> > every time at the kernel startup (on x86_64).
>
> Can you send me your modified patch?
Index: linux-2.6.18-rc3-mm2/fs/reiserfs/super.c
===================================================================
--- linux-2.6.18-rc3-mm2.orig/fs/reiserfs/super.c
+++ linux-2.6.18-rc3-mm2/fs/reiserfs/super.c
@@ -430,21 +430,29 @@ int remove_save_link(struct inode *inode
return journal_end(&th, inode->i_sb, JOURNAL_PER_BALANCE_CNT);
}
-static void reiserfs_put_super(struct super_block *s)
+static void reiserfs_kill_sb(struct super_block *s)
{
- struct reiserfs_transaction_handle th;
- th.t_trans_id = 0;
-
if (REISERFS_SB(s)->xattr_root) {
d_invalidate(REISERFS_SB(s)->xattr_root);
dput(REISERFS_SB(s)->xattr_root);
+ REISERFS_SB(s)->xattr_root = NULL;
}
if (REISERFS_SB(s)->priv_root) {
d_invalidate(REISERFS_SB(s)->priv_root);
dput(REISERFS_SB(s)->priv_root);
+ REISERFS_SB(s)->priv_root = NULL;
}
+ kill_block_super(s);
+}
+
+static void reiserfs_put_super(struct super_block *s)
+{
+ int i;
+ struct reiserfs_transaction_handle th;
+ th.t_trans_id = 0;
+
/* change file system state to current state if it was mounted with read-write permissions */
if (!(s->s_flags & MS_RDONLY)) {
if (!journal_begin(&th, s, 10)) {
@@ -2155,7 +2163,7 @@ struct file_system_type reiserfs_fs_type
.owner = THIS_MODULE,
.name = "reiserfs",
.get_sb = get_super_block,
- .kill_sb = kill_block_super,
+ .kill_sb = reiserfs_kill_sb,
.fs_flags = FS_REQUIRES_DEV,
};
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists