[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20090204185501.837ff5d6.kamezawa.hiroyu@jp.fujitsu.com>
Date: Wed, 4 Feb 2009 18:55:01 +0900
From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
Cc: "Swamy Gowda" <swamy@...ident.com>, <linux-kernel@...r.kernel.org>,
cl@...ux-foundation.org, Brice.Goglin@...ia.fr,
"linux-mm@...ck.org" <linux-mm@...ck.org>
Subject: [RFC][PATCH] release mmap_sem before starting migration (Was Re:
Need to take mmap_sem lock in move_pages.
On Wed, 4 Feb 2009 18:40:28 +0900
KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com> wrote:
> On Wed, 4 Feb 2009 18:36:00 +0900
> KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com> wrote:
> Maybe up_read() can be moved before do_migrate_pages(), I think.
>
How about this ?
==
mmap_sem can be released after page table walk ends.
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
---
mm/migrate.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: mmotm-2.6.29-Feb03/mm/migrate.c
===================================================================
--- mmotm-2.6.29-Feb03.orig/mm/migrate.c
+++ mmotm-2.6.29-Feb03/mm/migrate.c
@@ -875,13 +875,13 @@ put_and_set:
set_status:
pp->status = err;
}
+ up_read(&mm->mmap_sem);
err = 0;
if (!list_empty(&pagelist))
err = migrate_pages(&pagelist, new_page_node,
(unsigned long)pm);
- up_read(&mm->mmap_sem);
return err;
}
--
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