linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Mel Gorman <mgorman@suse.de>
To: Hugh Dickins <hughd@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] mm: replace init_page_accessed by __SetPageReferenced
Date: Mon, 30 Jun 2014 22:59:38 +0100	[thread overview]
Message-ID: <20140630215938.GR10819@suse.de> (raw)
In-Reply-To: <alpine.LSU.2.11.1406301408310.1096@eggly.anvils>

On Mon, Jun 30, 2014 at 02:09:49PM -0700, Hugh Dickins wrote:
> Do we really need an exported alias for __SetPageReferenced()?
> Its callers better know what they're doing, in which case the page
> would not be already marked referenced.  Kill init_page_accessed(),
> just __SetPageReferenced() inline.
> 
> Signed-off-by: Hugh Dickins <hughd@google.com>

Ok, fair enough. The context it was written in was that callers should not
need to know the internals of what mark_page_accessed does. Initially I
thought there might be filesystem users that really should not know the
internals but that is not necessary obviously. I still feel that
init_page_accessed shows the intent more clearly and you're certainly
right that the checking PageReferenced is redundant. I don't object to
the patch but I don't think it's obviously better either other than it
avoids the temptation of anyone using __SetPageReferenced incorrectly.

Acked-by: Mel Gorman <mgorman@suse.de>

-- 
Mel Gorman
SUSE Labs

--
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/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2014-06-30 21:59 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-30 21:08 [PATCH 1/2] shmem: fix init_page_accessed use to stop !PageLRU bug Hugh Dickins
2014-06-30 21:09 ` [PATCH 2/2] mm: replace init_page_accessed by __SetPageReferenced Hugh Dickins
2014-06-30 21:59   ` Mel Gorman [this message]
2014-06-30 22:00 ` [PATCH 1/2] shmem: fix init_page_accessed use to stop !PageLRU bug Mel Gorman

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=20140630215938.GR10819@suse.de \
    --to=mgorman@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=hughd@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.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;
as well as URLs for NNTP newsgroup(s).