thp: remove wake_up_interruptible in the exit path
authorXiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Mon, 8 Oct 2012 23:29:44 +0000 (16:29 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 9 Oct 2012 07:22:26 +0000 (16:22 +0900)
commit2017c0bff8ba79ea527361adbe19471e174775d6
treea5d6e611ac06180e19bc6a5a3189668259a99742
parente060f0e0139b83f05bb90fa05563d14179b9a7ff
thp: remove wake_up_interruptible in the exit path

Add the check of kthread_should_stop() to the conditions which are used to
wakeup on khugepaged_wait, then kthread_stop is enough to let the thread
exit

Signed-off-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/huge_memory.c