The patch titled Subject: sched/wait: assert the wait_queue_head lock is held in __wake_up_common has been added to the -mm tree. Its filename is sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Christoph Hellwig <hch@xxxxxx> Subject: sched/wait: assert the wait_queue_head lock is held in __wake_up_common Better ensure we actually hold the lock using lockdep than just commenting on it. Due to the various exported _locked interfaces it is far too easy to get the locking wrong. Link: http://lkml.kernel.org/r/20171214152344.6880-4-hch@xxxxxx Signed-off-by: Christoph Hellwig <hch@xxxxxx> Acked-by: Ingo Molnar <mingo@xxxxxxxxxx> Cc: Al Viro <viro@xxxxxxxxxxxxxxxxxx> Cc: Andrea Arcangeli <aarcange@xxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxxxxx> Cc: Jason Baron <jbaron@xxxxxxxxxx> Cc: Matthew Wilcox <mawilcox@xxxxxxxxxxxxx> Cc: Mike Rapoport <rppt@xxxxxxxxxxxxxxxxxx> Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx> Cc: Davidlohr Bueso <dave@xxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- diff -puN kernel/sched/wait.c~sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common kernel/sched/wait.c --- a/kernel/sched/wait.c~sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common +++ a/kernel/sched/wait.c @@ -69,6 +69,8 @@ static int __wake_up_common(struct wait_ wait_queue_entry_t *curr, *next; int cnt = 0; + lockdep_assert_held(&wq_head->lock); + if (bookmark && (bookmark->flags & WQ_FLAG_BOOKMARK)) { curr = list_next_entry(bookmark, entry); _ Patches currently in -mm which might be from hch@xxxxxx are epoll-use-the-waitqueue-lock-to-protect-ep-wq.patch sched-wait-assert-the-wait_queue_head-lock-is-held-in-__wake_up_common.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html