linux-kernel-test/kernel/events
Oleg Nesterov 2fd611a991 uprobes: Suppress uprobe_munmap() from mmput()
uprobe_munmap() does get_user_pages() and it is also called from
the final mmput()->exit_mmap() path. This slows down
exit/mmput() for no reason, and I think  it is simply
dangerous/wrong to try to fault-in a page into the dying mm. If
nothing else, this happens after the last sync_mm_rss(), afaics
handle_mm_fault() can change the task->rss_stat and make the
subsequent check_mm() unhappy.

Change uprobe_munmap() to check mm->mm_users != 0.

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Acked-by: Srikar Dronamraju <srikar.vnet.ibm.com>
Cc: Anton Arapov <anton@redhat.com>
Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Link: http://lkml.kernel.org/r/20120729182231.GA20336@redhat.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2012-07-30 11:27:21 +02:00
..
callchain.c perf: Don't call release_callchain_buffers() if allocation fails 2012-01-21 09:33:41 +01:00
core.c perf: Introduce perf_pmu_migrate_context() 2012-06-18 12:13:21 +02:00
hw_breakpoint.c Merge branch 'x86/cleanups' into perf/uprobes 2012-03-13 16:33:03 +01:00
internal.h Merge branch 'perf/urgent' into perf/core 2011-12-06 06:43:49 +01:00
Makefile uprobes: Move to kernel/events/ 2012-02-22 11:08:00 +01:00
ring_buffer.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2012-01-08 13:21:22 -08:00
uprobes.c uprobes: Suppress uprobe_munmap() from mmput() 2012-07-30 11:27:21 +02:00