From: Rik van Riel <riel@redhat.com>
To: Andrea Arcangeli <aarcange@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Hugh Dickins <hughd@google.com>,
linux-mm@kvack.org
Subject: Re: [PATCH] fix swapin race condition
Date: Fri, 03 Sep 2010 19:57:18 -0400 [thread overview]
Message-ID: <4C818B5E.5080507@redhat.com> (raw)
In-Reply-To: <20100903153958.GC16761@random.random>
On 09/03/2010 11:39 AM, Andrea Arcangeli wrote:
> From: Andrea Arcangeli<aarcange@redhat.com>
>
> The pte_same check is reliable only if the swap entry remains pinned
> (by the page lock on swapcache). We've also to ensure the swapcache
> isn't removed before we take the lock as try_to_free_swap won't care
> about the page pin.
>
> Signed-off-by: Andrea Arcangeli<aarcange@redhat.com>
Reviewed-by: Rik van Riel <riel@redhat.com>
Andrew, one of the possible impacts of this patch is that a
KSM-shared page can point to the anon_vma of another process,
which could exit before the page is freed.
This can leave a page with a pointer to a recycled anon_vma
object, or worse, a pointer to something that is no longer
an anon_vma.
Backporting this patch to -stable is worthwhile, IMHO.
--
All rights reversed
--
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>
next prev parent reply other threads:[~2010-09-04 0:57 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-03 15:39 [PATCH] fix swapin race condition Andrea Arcangeli
2010-09-03 20:02 ` Andrew Morton
2010-09-04 12:29 ` Andrea Arcangeli
2010-09-03 23:57 ` Rik van Riel [this message]
2010-09-06 2:35 ` Hugh Dickins
2010-09-15 23:02 ` Hugh Dickins
2010-09-15 23:42 ` Andrea Arcangeli
2010-09-16 0:10 ` Hugh Dickins
2010-09-16 21:03 ` Andrea Arcangeli
2010-09-16 21:08 ` Andrea Arcangeli
2010-09-17 2:31 ` Hugh Dickins
2010-09-18 13:19 ` Andrea Arcangeli
2010-09-20 2:35 ` Hugh Dickins
2010-09-20 2:40 ` [PATCH] mm: further " Hugh Dickins
2010-09-20 3:09 ` Rik van Riel
-- strict thread matches above, loose matches on Subject: below --
2010-07-09 0:23 [PATCH] " Andrea Arcangeli
2010-07-09 20:32 ` Hugh Dickins
2010-07-09 21:19 ` Hugh Dickins
2010-07-09 22:02 ` Rik van Riel
2010-07-13 1:08 ` Andrea Arcangeli
2010-07-13 21:30 ` Hugh Dickins
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=4C818B5E.5080507@redhat.com \
--to=riel@redhat.com \
--cc=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=hughd@google.com \
--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).