Commit 187226f5 authored by john stultz's avatar john stultz Committed by Linus Torvalds

futex_unlock_pi() hurts my brain and may cause application deadlock

Avoid futex_unlock_pi returning -EFAULT (which results in deadlock), by
clearing uval before jumping to retry_locked.
Signed-off-by: default avatarJohn Stultz <johnstul@us.ibm.com>
Acked-by: default avatarSteven Rostedt <rostedt@goodmis.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 42b88e6a
......@@ -1670,6 +1670,7 @@ static int futex_unlock_pi(u32 __user *uaddr, struct rw_semaphore *fshared)
attempt);
if (ret)
goto out;
uval = 0;
goto retry_unlocked;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment