From: Nick Piggin <npiggin@suse.de>
To: David Howells <dhowells@redhat.com>
Cc: torvalds@linux-foundation.org, akpm@linux-foundation.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Fix a bad bug in read_cache_page_async()
Date: Wed, 9 May 2007 14:19:37 +0200 [thread overview]
Message-ID: <20070509121937.GA24026@wotan.suse.de> (raw)
In-Reply-To: <20070509120201.6771.92968.stgit@warthog.cambridge.redhat.com>
On Wed, May 09, 2007 at 01:02:01PM +0100, David Howells wrote:
> Fix a bad bug in read_cache_page_async() introduced in commit:
>
> 6fe6900e1e5b6fa9e5c59aa5061f244fe3f467e2
>
> This adds:
>
> mark_page_accessed(page)
>
> into the error handling path in read_cache_page_async(). In such a case,
> 'page' holds the error code.
Obvious thinko. Thanks, ack.
>
> Signed-off-by: David Howells <dhowells@redhat.com>
> ---
>
> mm/filemap.c | 6 ++++--
> 1 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/mm/filemap.c b/mm/filemap.c
> index 9e56fd1..10d4fcf 100644
> --- a/mm/filemap.c
> +++ b/mm/filemap.c
> @@ -1784,7 +1784,7 @@ struct page *read_cache_page_async(struct address_space *mapping,
> retry:
> page = __read_cache_page(mapping, index, filler, data);
> if (IS_ERR(page))
> - goto out;
> + goto error;
> mark_page_accessed(page);
> if (PageUptodate(page))
> goto out;
> @@ -1803,9 +1803,11 @@ retry:
> if (err < 0) {
> page_cache_release(page);
> page = ERR_PTR(err);
> + goto error;
> }
> - out:
> +out:
> mark_page_accessed(page);
> +error:
> return page;
> }
> EXPORT_SYMBOL(read_cache_page_async);
next prev parent reply other threads:[~2007-05-09 12:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-09 12:02 David Howells
2007-05-09 12:07 ` Glauber de Oliveira Costa
2007-05-09 12:19 ` Nick Piggin [this message]
2007-05-09 12:22 ` David Howells
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=20070509121937.GA24026@wotan.suse.de \
--to=npiggin@suse.de \
--cc=akpm@linux-foundation.org \
--cc=dhowells@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.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
all inboxes | Powered by JetHome®