From: Ted Ts'o <tytso@mit.edu>
To: Markus Trippelsdorf <markus@trippelsdorf.de>,
sedat.dilek@gmail.com, LKML <linux-kernel@vger.kernel.org>,
linux-ext4@vger.kernel.org, sfr@canb.auug.org.au,
Arnd Bergmann <arnd@arndb.d
Subject: Re: [next-20101038] Call trace in ext4
Date: Thu, 28 Oct 2010 15:32:11 -0400 [thread overview]
Message-ID: <20101028193211.GA28126@thunk.org> (raw)
In-Reply-To: <20101028180118.GC6814@thunk.org>
On Thu, Oct 28, 2010 at 02:01:18PM -0400, Ted Ts'o wrote:
> On Thu, Oct 28, 2010 at 07:52:21PM +0200, Markus Trippelsdorf wrote:
> >
> > The same BUG (inode.c:2721) happend here today running latest vanilla
> > git. There is nothing in my logs unfortunately, but I shot a photo of
> > the trace (see attachment).
>
> I see, it's the page_buffers() call which is triggering. Looking into
> it...
Can folks let me know if this fixes the problem?
In this case I haven't been able to replicate the problem, but I've
eyeballed the problem and I'm about 90% certain this should fix
things. But I don't want to push this to Linus until I get
confirmation from you all that it fixes things. That's just one of
the ways in which your testing is critically important for ext4, so
thanks again for your help in the past, present, and future.
Thanks!!
- Ted
commit 51279fcb9720aa856ad81673886ca2349a373dac
Author: Theodore Ts'o <tytso@mit.edu>
Date: Thu Oct 28 15:15:21 2010 -0400
ext4: BUG_ON fix: check if page has buffers before calling page_buffers()
We need to make check if a page does not have buffes by checking
page_has_buffers(page) before calling page_buffers(page) in
ext4_writepage(). Otherwise page_buffers() could throw a BUG_ON.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index 2d6c6c8..1916164 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -2718,7 +2718,7 @@ static int ext4_writepage(struct page *page,
* try to create them using __block_write_begin. If this
* fails, redirty the page and move on.
*/
- if (!page_buffers(page)) {
+ if (!page_has_buffers(page)) {
if (__block_write_begin(page, 0, len,
noalloc_get_block_write)) {
redirty_page:
@@ -2732,12 +2732,10 @@ static int ext4_writepage(struct page *page,
if (walk_page_buffers(NULL, page_bufs, 0, len, NULL,
ext4_bh_delay_or_unwritten)) {
/*
- * We don't want to do block allocation So redirty the
- * page and return We may reach here when we do a
- * journal commit via
- * journal_submit_inode_data_buffers. If we don't
- * have mapping block we just ignore them. We can also
- * reach here via shrink_page_list
+ * We don't want to do block allocation, so redirty
+ * the page and return. We may reach here when we do
+ * a journal commit via journal_submit_inode_data_buffers.
+ * We can also reach here via shrink_page_list
*/
goto redirty_page;
}
next prev parent reply other threads:[~2010-10-28 19:32 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-28 10:05 [next-20101038] Call trace in ext4 Sedat Dilek
2010-10-28 10:34 ` [next-20101028] " Sedat Dilek
2010-10-28 15:08 ` Sedat Dilek
2010-10-28 15:27 ` Ted Ts'o
2010-10-28 17:52 ` [next-20101038] " Markus Trippelsdorf
2010-10-28 18:01 ` Ted Ts'o
2010-10-28 18:16 ` Eric Sandeen
2010-10-28 19:32 ` Ted Ts'o [this message]
2010-10-28 19:36 ` Eric Sandeen
2010-10-28 19:54 ` Ted Ts'o
2010-10-28 19:54 ` Sedat Dilek
2010-10-28 20:05 ` Ted Ts'o
2010-10-28 20:15 ` Sedat Dilek
2010-10-28 20:37 ` Ted Ts'o
2010-10-28 21:02 ` Sedat Dilek
2010-10-28 21:06 ` Ted Ts'o
2010-10-28 21:17 ` Sedat Dilek
2010-10-28 18:20 ` Sedat Dilek
2010-10-28 18:34 ` Sedat Dilek
2010-10-28 18:55 ` Ted Ts'o
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=20101028193211.GA28126@thunk.org \
--to=tytso@mit.edu \
--cc=arnd@arndb.d \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=markus@trippelsdorf.de \
--cc=sedat.dilek@gmail.com \
--cc=sfr@canb.auug.org.au \
/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;
as well as URLs for NNTP newsgroup(s).