From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Andrew Morton <akpm@osdl.org>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] nfs: fix NR_FILE_DIRTY underflow
Date: Wed, 13 Dec 2006 07:26:21 -0500 [thread overview]
Message-ID: <1166012781.5695.18.camel@lade.trondhjem.org> (raw)
In-Reply-To: <1166011958.32332.97.camel@twins>
On Wed, 2006-12-13 at 13:12 +0100, Peter Zijlstra wrote:
> Still testing this patch, but it looks good so far.
>
> ---
> Just setting PG_dirty can cause NR_FILE_DIRTY to underflow
> which is bad (TM).
>
> Use set_page_dirty() which will do the right thing.
Actually, I'd prefer to have it do the right thing by getting rid of
that call to test_clear_page_dirty() inside
invalidate_inode_pages2_range(). That is causing loss of data integrity,
and is what is causing us to have to hack NFS in the first place.
Cheers
Trond
> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
> ---
> fs/nfs/file.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> Index: linux-2.6-git2/fs/nfs/file.c
> ===================================================================
> --- linux-2.6-git2.orig/fs/nfs/file.c 2006-12-13 12:54:55.000000000 +0100
> +++ linux-2.6-git2/fs/nfs/file.c 2006-12-13 12:55:12.000000000 +0100
> @@ -321,7 +321,7 @@ static int nfs_release_page(struct page
> if (!(gfp & __GFP_FS))
> return 0;
> /* Hack... Force nfs_wb_page() to write out the page */
> - SetPageDirty(page);
> + set_page_dirty(page);
> return !nfs_wb_page(page->mapping->host, page);
> }
>
>
>
next prev parent reply other threads:[~2006-12-13 12:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-13 12:12 Peter Zijlstra
2006-12-13 12:26 ` Trond Myklebust [this message]
2006-12-13 15:01 ` Peter Zijlstra
2006-12-13 17:40 ` Trond Myklebust
2006-12-13 18:48 ` Peter Zijlstra
2006-12-14 1:29 ` Andrew Morton
2006-12-14 1:41 ` Andrew Morton
2006-12-14 14:52 ` Trond Myklebust
2006-12-13 16:22 ` Peter Zijlstra
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=1166012781.5695.18.camel@lade.trondhjem.org \
--to=trond.myklebust@fys.uio.no \
--cc=a.p.zijlstra@chello.nl \
--cc=akpm@osdl.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
all inboxes | Powered by JetHome®