linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Tweedie <sct@redhat.com>
To: Marcelo Tosatti <marcelo@conectiva.com.br>, linux-kernel@vger.kernel.org
Cc: Stephen Tweedie <sct@redhat.com>
Subject: [Patch 1/7] 2.4.20-pre4/ext3: Fix LVM snapshot deadlock
Date: Thu, 26 Sep 2002 14:55:31 +0100	[thread overview]
Message-ID: <200209261355.g8QDtVC16990@sisko.scot.redhat.com> (raw)

Fix LVM snapshot deadlock: it is a bad idea to try to flush all running
transactions while we already hold the superblock lock.  Drop the sb lock
while we flush.

This only affects kernels that have the extra LVM VFS locking added in
for filesystem quiescing on snapshots.

--- linux-2.4-ext3merge/fs/ext3/super.c.=K0000=.orig	Thu Sep 26 12:19:14 2002
+++ linux-2.4-ext3merge/fs/ext3/super.c	Thu Sep 26 12:25:37 2002
@@ -1588,8 +1588,10 @@
 		journal_t *journal = EXT3_SB(sb)->s_journal;
 
 		/* Now we set up the journal barrier. */
+		unlock_super(sb);
 		journal_lock_updates(journal);
 		journal_flush(journal);
+		lock_super(sb);
 
 		/* Journal blocked and flushed, clear needs_recovery flag. */
 		EXT3_CLEAR_INCOMPAT_FEATURE(sb, EXT3_FEATURE_INCOMPAT_RECOVER);

                 reply	other threads:[~2002-09-26 13:51 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=200209261355.g8QDtVC16990@sisko.scot.redhat.com \
    --to=sct@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo@conectiva.com.br \
    --subject='Re: [Patch 1/7] 2.4.20-pre4/ext3: Fix LVM snapshot deadlock' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).