Skip to content
Commit dfd01f02 authored by Peter Zijlstra's avatar Peter Zijlstra Committed by Linus Torvalds
Browse files

sched/wait: Fix the signal handling fix



Jan Stancek reported that I wrecked things for him by fixing things for
Vladimir :/

His report was due to an UNINTERRUPTIBLE wait getting -EINTR, which
should not be possible, however my previous patch made this possible by
unconditionally checking signal_pending().

We cannot use current->state as was done previously, because the
instruction after the store to that variable it can be changed.  We must
instead pass the initial state along and use that.

Fixes: 68985633 ("sched/wait: Fix signal handling in bit wait helpers")
Reported-by: default avatarJan Stancek <jstancek@redhat.com>
Reported-by: default avatarChris Mason <clm@fb.com>
Tested-by: default avatarJan Stancek <jstancek@redhat.com>
Tested-by: default avatarVladimir Murzin <vladimir.murzin@arm.com>
Tested-by: default avatarChris Mason <clm@fb.com>
Reviewed-by: default avatarPaul Turner <pjt@google.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: tglx@linutronix.de
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: hpa@zytor.com
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent fc891828
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