All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrea Arcangeli <aarcange@redhat.com>
To: Minchan Kim <minchan@kernel.org>
Cc: Kamezawa Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	Mel Gorman <mgorman@suse.de>, Michal Hocko <mhocko@suse.cz>
Subject: Re: [PATCH] mm: do not use page_count without a page pin
Date: Mon, 11 Jun 2012 16:41:32 +0200	[thread overview]
Message-ID: <20120611144132.GT3094@redhat.com> (raw)
In-Reply-To: <20120611133043.GA2340@barrios>

Hi Minchan,

On Mon, Jun 11, 2012 at 10:30:43PM +0900, Minchan Kim wrote:
> AFAIUC, you mean we have to increase reference count of head page?
> If so, it's not in __count_immobile_pages because it is already race-likely function
> so it shouldn't be critical although race happens.

I meant, shouldn't we take into account the full size? If it's in the
lru the whole thing can be moved away.

  if (!PageLRU(page)) {
     nr_pages = hpage_nr_pages(page);
     barrier();
     found += nr_pages;
     iter += nr_pages-1;
  }

--
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>

WARNING: multiple messages have this Message-ID (diff)
From: Andrea Arcangeli <aarcange@redhat.com>
To: Minchan Kim <minchan@kernel.org>
Cc: Kamezawa Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	Mel Gorman <mgorman@suse.de>, Michal Hocko <mhocko@suse.cz>
Subject: Re: [PATCH] mm: do not use page_count without a page pin
Date: Mon, 11 Jun 2012 16:41:32 +0200	[thread overview]
Message-ID: <20120611144132.GT3094@redhat.com> (raw)
In-Reply-To: <20120611133043.GA2340@barrios>

Hi Minchan,

On Mon, Jun 11, 2012 at 10:30:43PM +0900, Minchan Kim wrote:
> AFAIUC, you mean we have to increase reference count of head page?
> If so, it's not in __count_immobile_pages because it is already race-likely function
> so it shouldn't be critical although race happens.

I meant, shouldn't we take into account the full size? If it's in the
lru the whole thing can be moved away.

  if (!PageLRU(page)) {
     nr_pages = hpage_nr_pages(page);
     barrier();
     found += nr_pages;
     iter += nr_pages-1;
  }

  reply	other threads:[~2012-06-11 14:41 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-11  0:17 [PATCH] mm: do not use page_count without a page pin Minchan Kim
2012-06-11  0:17 ` Minchan Kim
2012-06-11  0:23 ` Wanpeng Li
2012-06-11  0:23   ` Wanpeng Li
2012-06-11  2:09   ` Minchan Kim
2012-06-11  2:09     ` Minchan Kim
2012-06-11  7:20 ` Kamezawa Hiroyuki
2012-06-11  7:20   ` Kamezawa Hiroyuki
2012-06-11  7:44   ` Andrea Arcangeli
2012-06-11  7:44     ` Andrea Arcangeli
2012-06-11  8:48     ` Kamezawa Hiroyuki
2012-06-11  8:48       ` Kamezawa Hiroyuki
2012-06-11 13:30     ` Minchan Kim
2012-06-11 13:30       ` Minchan Kim
2012-06-11 14:41       ` Andrea Arcangeli [this message]
2012-06-11 14:41         ` Andrea Arcangeli
2012-06-11 22:49         ` Minchan Kim
2012-06-11 22:49           ` Minchan Kim
2012-06-14  1:21           ` Andrea Arcangeli
2012-06-14  1:21             ` Andrea Arcangeli
2012-06-14  1:49             ` Minchan Kim
2012-06-14  1:49               ` Minchan Kim

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=20120611144132.GT3094@redhat.com \
    --to=aarcange@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mgorman@suse.de \
    --cc=mhocko@suse.cz \
    --cc=minchan@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.