inotify: fix lock ordering wrt do_page_fault's mmap_sem
authorNick Piggin <nickpiggin@yahoo.com.au>
Thu, 2 Oct 2008 21:50:12 +0000 (14:50 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 2 Oct 2008 22:53:13 +0000 (15:53 -0700)
commit16dbc6c9616363fe53811abcbd935336dc0a0f01
treedef1129950caf1e861563b7cbdc1874e7c41fc5c
parent08650869e0ec581f8d88cfdb563d37f5383abfe2
inotify: fix lock ordering wrt do_page_fault's mmap_sem

Fix inotify lock order reversal with mmap_sem due to holding locks over
copy_to_user.

Signed-off-by: Nick Piggin <npiggin@suse.de>
Reported-by: "Daniel J Blueman" <daniel.blueman@gmail.com>
Tested-by: "Daniel J Blueman" <daniel.blueman@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/inotify_user.c
include/asm-x86/uaccess_64.h