public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Johann Lombardi <johann@clusterfs.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Clear PG_error before reading a page
Date: Tue, 15 May 2007 23:01:24 +0200	[thread overview]
Message-ID: <20070515210124.GA23698@chiva> (raw)
In-Reply-To: <20070515101144.f7072476.akpm@linux-foundation.org>

On Tue, May 15, 2007 at 10:11:44AM -0700, Andrew Morton wrote:
> We need to make sure that this page has PG_uptodate cleared, so
> that a re-read is forced.  And the affected buffer_head, if any, should have
> buffer_uptodate() cleared.

ok.

> This change might have horrid interactions with readahead and various
> application access patterns: if for some reason a dud sector takes 30
> seconds of driver futzing to return -EIO and someone (application or
> kernel) tries to read the same sector tens or hundreds of times, suckiness
> ensues.  This will be hard to test for.

Yes, I agree. So according to you, what's the best way to address the
initial problem (i.e. PG_error never cleared)?

> Most reads don't (or shouldn't) go through block_read_full_page().
> mpage_readpages() does the heavy lifting.

Yes, indeed. However, as soon as a call to get_block() fails,
do_mpage_readpage() will call block_read_full_page() which will attach
buffers to this page.
Consequently, all subsequent reads will go through block_read_full_page().

Johann

  reply	other threads:[~2007-05-15 21:01 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-15 14:37 Clear PG_error before reading a page Johann Lombardi
2007-05-15 17:11 ` Andrew Morton
2007-05-15 21:01   ` Johann Lombardi [this message]
2007-05-15 21:23     ` Andrew Morton
2007-05-16 15:39       ` Johann Lombardi
2007-05-16 15:49         ` Nick Piggin
2007-05-16 16:12         ` Andrew Morton
2007-05-17 11:42           ` Johann Lombardi
2007-05-17 16:47             ` Andrew Morton
2007-05-29 17:06               ` Johann Lombardi

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=20070515210124.GA23698@chiva \
    --to=johann@clusterfs.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox