public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Kleikamp <dave.kleikamp@oracle.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: jfs-discussion@lists.sourceforge.net, xfs@oss.sgi.com
Subject: [PATCH]  jfs: flush journal completely before releasing metadata inodes
Date: Mon, 01 Aug 2011 13:29:26 -0500	[thread overview]
Message-ID: <4E36F086.4070900@oracle.com> (raw)
In-Reply-To: <4E32D9EB.9020406@oracle.com>

On 07/29/2011 11:03 AM, Dave Kleikamp wrote:
> On 07/29/2011 10:50 AM, Christoph Hellwig wrote:
>> The patch below adds basic jfs support to xfstests.  Unfortunately it
>> doesn't get very far, as test 001 already blows up with a kernel crash,
>> as do 011 and 013 as other random picks.
> 
> Great :-)
> 
> Seems to be a good idea to support jfs. I'll carve out some time to
> reproduce and debug the crashes.

This fixes a race during unmount. We need to not only make sure that
the journal is completely written, but that the metadata changes make
it to disk before releasing ipimap and ipbmap.

Signed-off-by: Dave Kleikamp <dave.kleikamp@oracle.com>
---
 fs/jfs/jfs_umount.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/jfs/jfs_umount.c b/fs/jfs/jfs_umount.c
index adcf92d..7971f37 100644
--- a/fs/jfs/jfs_umount.c
+++ b/fs/jfs/jfs_umount.c
@@ -68,7 +68,7 @@ int jfs_umount(struct super_block *sb)
 		/*
 		 * Wait for outstanding transactions to be written to log:
 		 */
-		jfs_flush_journal(log, 1);
+		jfs_flush_journal(log, 2);
 
 	/*
 	 * close fileset inode allocation map (aka fileset inode)
@@ -146,7 +146,7 @@ int jfs_umount_rw(struct super_block *sb)
 	 *
 	 * remove file system from log active file system list.
 	 */
-	jfs_flush_journal(log, 1);
+	jfs_flush_journal(log, 2);
 
 	/*
 	 * Make sure all metadata makes it to disk

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

  reply	other threads:[~2011-08-01 18:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-29 15:50 [PATCH, RFC] jfs support for xfstests Christoph Hellwig
2011-07-29 16:03 ` [Jfs-discussion] " Dave Kleikamp
2011-08-01 18:29   ` Dave Kleikamp [this message]
2011-08-01 18:32     ` [PATCH] jfs: flush journal completely before releasing metadata inodes Christoph Hellwig
2011-08-01 20:04       ` Dave Kleikamp
2011-08-02 10:25         ` Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E36F086.4070900@oracle.com \
    --to=dave.kleikamp@oracle.com \
    --cc=hch@infradead.org \
    --cc=jfs-discussion@lists.sourceforge.net \
    --cc=xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox