Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3e875238 authored by Mikulas Patocka's avatar Mikulas Patocka Committed by Ingo Molnar
Browse files

sched/wait: Remove might_sleep() from wait_event_cmd()



The patch e22b886a ("sched/wait: Add might_sleep() checks")
introduced a bug in the raid5 subsystem.

The function raid5_quiesce() (and resize_stripes()) uses the 'cmd'
part to release and acquire a spinlock (so we call the sleep
primitives in atomic context), and therefore we cannot do the
might_sleep() check.

Remove it.

Fixes: e22b886a ("sched/wait: Add might_sleep() checks")
Signed-off-by: default avatarMikulas Patocka <mpatocka@redhat.com>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/alpine.LRH.2.02.1502020935580.13510@file01.intranet.prod.int.rdu2.redhat.com


Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent bb2bc55a
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -363,7 +363,6 @@ do { \
 */
#define wait_event_cmd(wq, condition, cmd1, cmd2)			\
do {									\
	might_sleep();							\
	if (condition)							\
		break;							\
	__wait_event_cmd(wq, condition, cmd1, cmd2);			\