From: Andrew Morton <akpm@osdl.org>
To: Andrea Arcangeli <andrea@suse.de>
Cc: linux-kernel@vger.kernel.org, torvalds@osdl.org, mason@suse.com
Subject: Re: writepage fs corruption fixes
Date: Thu, 8 Jul 2004 21:29:23 -0700 [thread overview]
Message-ID: <20040708212923.406135f0.akpm@osdl.org> (raw)
In-Reply-To: <20040709040151.GB20947@dualathlon.random>
Andrea Arcangeli <andrea@suse.de> wrote:
>
> 1) The major one (the only one I believe that was triggering [only on
> ext2 due the fact mpage is working only there]) is the marking of the bh
> clean despite we could still run into the "confused" path. After that
> the confused path really becomes confused and it writes nothing and fs
> corruption triggers silenty (the reugular writepage only writes bh that
> are marked dirty, it never attempts to submit_bh anything marked clean).
> The mpage-writepage code must never mark the bh clean as far as it
> wants to still fallback in the regular writepage which depends on the bh
> to be dirty (i.e. the "goto confused" path). This could only triggers
> with memory pressure (it also needs buffer_heads_over_limit == 0, and
> that is frequent under mm pressure).
ooh, nasty, yes. You must be testing the crap out if it.
> 3) Third bug is in the regular writepage, the nr_underway == 0 code was
> walking buffers on an unlocked page without keeping the bh pinned, and
> in turn the bh could be released under it by the VM. Fix is to delay the
> put_bh loop. (this might have triggered but it's not certain)
PG_writeback protects the page from truncate, from invalidate and from page
reclaim. pagevec_strip() won't touch the buffers due to the
PageWriteback() test in try_to_release_page(). So I think we're OK in
there. I can add a couple more coment fixes for this.
next prev parent reply other threads:[~2004-07-09 4:30 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-09 4:01 writepage fs corruption fixes Andrea Arcangeli
2004-07-09 4:06 ` Andrea Arcangeli
2004-07-09 4:19 ` Andrea Arcangeli
2004-07-09 4:29 ` Andrew Morton [this message]
2004-07-09 4:42 ` Andrea Arcangeli
2004-07-09 4:56 ` Andrew Morton
2004-07-09 12:43 ` Chris Mason
2004-07-10 0:16 ` Andrea Arcangeli
2004-07-10 1:07 ` Andrea Arcangeli
2004-07-10 4:30 ` Andrew Morton
2004-07-10 4:59 ` Andrea Arcangeli
2004-07-10 5:56 ` Andrew Morton
2004-07-10 6:11 ` Andrea Arcangeli
2004-07-10 6:13 ` Andrew Morton
2004-07-14 16:14 ` Andrea Arcangeli
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=20040708212923.406135f0.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=andrea@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=mason@suse.com \
--cc=torvalds@osdl.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.