From: "Nate Diller" <nate.diller@gmail.com>
To: "Christoph Lameter" <clameter@sgi.com>
Cc: "Andrew Morton" <akpm@linux-foundation.org>,
"Satyam Sharma" <satyam.sharma@gmail.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] zero_user_page uses in fs/buffer.c and fs/libfs.c
Date: Tue, 1 May 2007 19:27:16 -0700 [thread overview]
Message-ID: <5c49b0ed0705011927n66208c1egd7cfdb6985dc901b@mail.gmail.com> (raw)
In-Reply-To: <5c49b0ed0705011916y89212c0v1cec1cb1edae052f@mail.gmail.com>
On 5/1/07, Nate Diller <nate.diller@gmail.com> wrote:
> On 5/1/07, Christoph Lameter <clameter@sgi.com> wrote:
> > On Tue, 1 May 2007, Andrew Morton wrote:
> >
> > > As Satyam said, this will sometimes cause us to map and unmap the page
> > > twice, and to run flush_dcache_page() twice. In not-terribly-uncommon
> > > circumstances in very frequently called functions.
> > >
> > > Doesn't seem worth it to me.
> >
> > Ok but we have that code three times. Should I add a variant of
> > zero_user_page that zeroes everything but the section specified?
> >
> > zero_user_page_allbut() ?
>
> the function already exists, it's called simple_prepare_write(), and i
> thought there were patches to convert those callsites in -mm ...
> although it looks like i let a review comment on that slide by. I
> need to redo a bunch of patches for re-submission anyway, so i guess
> i'll deal with that tomorrow.
>
> NATE
>
well, leave it to me to reply too quickly, sorry. i think we should
leave simple_prepare_write() the way it is, since it's a library
function itself. the other two callsites in your patch are buffers,
which may themselves be smaller than a page so you would need a
special function for just those two uses, there's no other way to
avoid making two calls to flush_dcache_page(). if it's tremendously
important to you to eliminate open coding of these, maybe make a
'static int buffer_prepare_write()' or some such in fs/buffer.c
NATE
next prev parent reply other threads:[~2007-05-02 2:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-30 6:14 Christoph Lameter
2007-04-30 6:53 ` Satyam Sharma
2007-04-30 7:04 ` Christoph Lameter
2007-05-02 0:26 ` Andrew Morton
2007-05-02 1:09 ` Christoph Lameter
2007-05-02 2:16 ` Nate Diller
2007-05-02 2:27 ` Nate Diller [this message]
2007-05-02 3:58 ` Christoph Lameter
2007-05-02 4:09 ` Andrew Morton
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=5c49b0ed0705011927n66208c1egd7cfdb6985dc901b@mail.gmail.com \
--to=nate.diller@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=clameter@sgi.com \
--cc=linux-kernel@vger.kernel.org \
--cc=satyam.sharma@gmail.com \
/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®