summaryrefslogtreecommitdiffstats
path: root/mm/sparse-vmemmap.c
diff options
context:
space:
mode:
authorChristoph Lameter2008-11-06 21:53:30 +0100
committerLinus Torvalds2008-11-07 00:41:18 +0100
commit0aedadf91a70a11c4a3e7c7d99b21e5528af8d5d (patch)
tree9e2529fa79ff4134f99772b5ed3693316e2221a5 /mm/sparse-vmemmap.c
parentfbdev: add new framebuffer driver for Fujitsu MB862xx GDCs (diff)
downloadkernel-qcow2-linux-0aedadf91a70a11c4a3e7c7d99b21e5528af8d5d.tar.gz
kernel-qcow2-linux-0aedadf91a70a11c4a3e7c7d99b21e5528af8d5d.tar.xz
kernel-qcow2-linux-0aedadf91a70a11c4a3e7c7d99b21e5528af8d5d.zip
mm: move migrate_prep out from under mmap_sem
Move the migrate_prep outside the mmap_sem for the following system calls 1. sys_move_pages 2. sys_migrate_pages 3. sys_mbind() It really does not matter when we flush the lru. The system is free to add pages onto the lru even during migration which will make the page migration either skip the page (mbind, migrate_pages) or return a busy state (move_pages). Fixes this lockdep warning (and potential deadlock): Some VM place has mmap_sem -> kevent_wq via lru_add_drain_all() net/core/dev.c::dev_ioctl() has rtnl_lock -> mmap_sem (*) the ioctl has copy_from_user() and it can do page fault. linkwatch_event has kevent_wq -> rtnl_lock Signed-off-by: Christoph Lameter <cl@linux-foundation.org> Cc: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Reported-by: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Nick Piggin <nickpiggin@yahoo.com.au> Cc: Hugh Dickins <hugh@veritas.com> Cc: Rik van Riel <riel@redhat.com> Cc: Lee Schermerhorn <lee.schermerhorn@hp.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/sparse-vmemmap.c')
0 files changed, 0 insertions, 0 deletions