[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1297126056-14322-1-git-send-email-walken@google.com>
Date: Mon, 7 Feb 2011 16:47:34 -0800
From: Michel Lespinasse <walken@...gle.com>
To: linux-mm@...ck.org, Lee Schermerhorn <lee.schermerhorn@...com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>,
Hugh Dickins <hughd@...gle.com>,
Rik van Riel <riel@...hat.com>,
Andrea Arcangeli <aarcange@...hat.com>,
linux-kernel@...r.kernel.org
Subject: [PATCH 0/2] page munlock issues when breaking up COW
It looks like there is a race in the do_wp_page() code that munlocks the
old page after breaking up COW. The pte still points to that old page,
so I don't see that we are protected against vmscan mlocking back the
page right away. This can be easily worked around by moving that code to
the end of do_wp_page(), after the pte has been pointed to the new page.
Also, the corresponding code in __do_fault() seems entirely unnecessary,
since there was never a pte pointing to the old page in our vma.
Michel Lespinasse (2):
mlock: fix race when munlocking pages in do_wp_page()
mlock: do not munlock pages in __do_fault()
mm/memory.c | 32 ++++++++++++--------------------
1 files changed, 12 insertions(+), 20 deletions(-)
--
1.7.3.1
--
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