From: Hugh Dickins <hughd@google.com>
To: Matthew Wilcox <willy@linux.intel.com>
Cc: linux-mm <linux-mm@kvack.org>, Wu Fengguang <fengguang.wu@intel.com>
Subject: Re: Setting of the PageReadahed bit
Date: Fri, 3 Jun 2011 20:15:38 -0700 [thread overview]
Message-ID: <BANLkTimc7wTyn0sVn+4OCL45_MOqhyV=QhJqV-GgXt_p290KwA@mail.gmail.com> (raw)
In-Reply-To: <20110603115519.GI4061@linux.intel.com>
On Fri, Jun 3, 2011 at 4:55 AM, Matthew Wilcox <willy@linux.intel.com> wrote:
> The exact definition of PageReadahead doesn't seem to be documented
> anywhere. I'm assuming it means "This page was not directly requested;
> it is being read for prefetching purposes", exactly like the READA
> semantics.
>
> If my interpretation is correct, then the implementation in
> __do_page_cache_readahead is wrong:
>
> if (page_idx == nr_to_read - lookahead_size)
> SetPageReadahead(page);
>
> It'll only set the PageReadahead bit on one page. The patch below fixes
> this ... if my understanding is correct.
Incorrect I believe: it's a trigger to say, when you get this far,
it's time to think about kicking off the next read.
>
> If my understanding is wrong, then how are readpage/readpages
> implementations supposed to know that the VM is only prefetching these
> pages, and they're not as important as metadata (dependent) reads?
I don't think they do know at present; but I can well imagine there
may be advantage in them knowing.
Hugh
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2011-06-04 3:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-03 11:55 Matthew Wilcox
2011-06-04 3:15 ` Hugh Dickins [this message]
2011-06-05 7:54 ` Wu Fengguang
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='BANLkTimc7wTyn0sVn+4OCL45_MOqhyV=QhJqV-GgXt_p290KwA@mail.gmail.com' \
--to=hughd@google.com \
--cc=fengguang.wu@intel.com \
--cc=linux-mm@kvack.org \
--cc=willy@linux.intel.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