[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <28c262360906150609gd736bf7p7a57de1b81cedd97@mail.gmail.com>
Date: Mon, 15 Jun 2009 22:09:03 +0900
From: Minchan Kim <minchan.kim@...il.com>
To: Wu Fengguang <fengguang.wu@...el.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
Andi Kleen <ak@...ux.intel.com>, Ingo Molnar <mingo@...e.hu>,
Mel Gorman <mel@....ul.ie>,
Thomas Gleixner <tglx@...utronix.de>,
"H. Peter Anvin" <hpa@...or.com>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Nick Piggin <npiggin@...e.de>,
Hugh Dickins <hugh.dickins@...cali.co.uk>,
Andi Kleen <andi@...stfloor.org>,
"riel@...hat.com" <riel@...hat.com>,
"chris.mason@...cle.com" <chris.mason@...cle.com>,
"linux-mm@...ck.org" <linux-mm@...ck.org>
Subject: Re: [PATCH 09/22] HWPOISON: Handle hardware poisoned pages in
try_to_unmap
On Mon, Jun 15, 2009 at 11:45 AM, Wu Fengguang<fengguang.wu@...el.com> wrote:
> From: Andi Kleen <ak@...ux.intel.com>
>
> When a page has the poison bit set replace the PTE with a poison entry.
> This causes the right error handling to be done later when a process runs
> into it.
>
> Also add a new flag to not do that (needed for the memory-failure handler
> later)
>
> Reviewed-by: Wu Fengguang <fengguang.wu@...el.com>
> Signed-off-by: Andi Kleen <ak@...ux.intel.com>
>
> ---
> include/linux/rmap.h | 1 +
> mm/rmap.c | 9 ++++++++-
> 2 files changed, 9 insertions(+), 1 deletion(-)
>
> --- sound-2.6.orig/mm/rmap.c
> +++ sound-2.6/mm/rmap.c
> @@ -958,7 +958,14 @@ static int try_to_unmap_one(struct page
> /* Update high watermark before we lower rss */
> update_hiwater_rss(mm);
>
> - if (PageAnon(page)) {
> + if (PageHWPoison(page) && !(flags & TTU_IGNORE_HWPOISON)) {
> + if (PageAnon(page))
> + dec_mm_counter(mm, anon_rss);
> + else if (!is_migration_entry(pte_to_swp_entry(*pte)))
Isn't it straightforward to use !is_hwpoison_entry ?
--
Kinds regards,
Minchan Kim
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists