From: Andrew Morton <akpm@digeo.com>
To: Steven Pratt <slpratt@austin.ibm.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: ext3 umount hangs
Date: Thu, 19 Jun 2003 13:10:34 -0700 [thread overview]
Message-ID: <20030619131034.5be8232b.akpm@digeo.com> (raw)
In-Reply-To: <3EF20E86.3030102@austin.ibm.com>
Steven Pratt <slpratt@austin.ibm.com> wrote:
>
> Here is the trace of the hung process:
>
> umount D 00000001 290213268 18747 18746 (NOTLB)
> Call Trace:
> [<c01a1ae8>] journal_kill_thread+0xa8/0xe0
whoops. I bet you're seeing this when using some script which does the
unmount.
Might this help?
diff -puN fs/jbd/journal.c~kjournald-shutdown-fix fs/jbd/journal.c
--- 25/fs/jbd/journal.c~kjournald-shutdown-fix 2003-06-19 12:58:43.000000000 -0700
+++ 25-akpm/fs/jbd/journal.c 2003-06-19 12:58:43.000000000 -0700
@@ -161,7 +161,7 @@ loop:
del_timer_sync(journal->j_commit_timer);
journal_commit_transaction(journal);
spin_lock(&journal->j_state_lock);
- goto loop;
+ goto end_loop;
}
wake_up(&journal->j_wait_done_commit);
@@ -210,7 +210,7 @@ loop:
journal->j_commit_request = transaction->t_tid;
jbd_debug(1, "woke because of timeout\n");
}
-
+end_loop:
if (!(journal->j_flags & JFS_UNMOUNT))
goto loop;
@@ -230,12 +230,16 @@ static void journal_start_thread(journal
static void journal_kill_thread(journal_t *journal)
{
+ spin_lock(&journal->j_state_lock);
journal->j_flags |= JFS_UNMOUNT;
while (journal->j_task) {
wake_up(&journal->j_wait_commit);
+ spin_unlock(&journal->j_state_lock);
wait_event(journal->j_wait_done_commit, journal->j_task == 0);
+ spin_lock(&journal->j_state_lock);
}
+ spin_unlock(&journal->j_state_lock);
}
/*
_
next prev parent reply other threads:[~2003-06-19 19:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-19 17:01 Steven Pratt
2003-06-19 17:58 ` Andrew Morton
2003-06-19 18:04 ` Steven Pratt
2003-06-19 19:27 ` Steven Pratt
2003-06-19 20:10 ` Andrew Morton [this message]
2003-06-19 20:22 ` Steven Pratt
2003-06-20 16:48 ` Steven Pratt
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=20030619131034.5be8232b.akpm@digeo.com \
--to=akpm@digeo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=slpratt@austin.ibm.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
all inboxes | Powered by JetHome®