]> www.infradead.org Git - users/jedix/linux-maple.git/commit
sched/wait: Fix the signal handling fix
authorPeter Zijlstra <peterz@infradead.org>
Sun, 13 Dec 2015 21:11:16 +0000 (22:11 +0100)
committerChuck Anderson <chuck.anderson@oracle.com>
Tue, 30 May 2017 06:26:38 +0000 (23:26 -0700)
commit8acadcf4f7a973d6093eda5a4eec7eba34a4d950
tree28f6622efed076f3389e9d07e5bdba51adf2b50c
parent91da2889e92ce475a8a6579ad8c37ac5ab5366fc
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: 68985633bccb ("sched/wait: Fix signal handling in bit wait helpers")
Reported-by: Jan Stancek <jstancek@redhat.com>
Reported-by: Chris Mason <clm@fb.com>
Tested-by: Jan Stancek <jstancek@redhat.com>
Tested-by: Vladimir Murzin <vladimir.murzin@arm.com>
Tested-by: Chris Mason <clm@fb.com>
Reviewed-by: Paul 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: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Orabug: 25908266
(cherry picked from commit dfd01f026058a59a513f8a365b439a0681b803af)
Signed-off-by: Chuck Anderson <chuck.anderson@oracle.com>
fs/cifs/inode.c
fs/nfs/inode.c
fs/nfs/internal.h
fs/nfs/pagelist.c
fs/nfs/pnfs.c
include/linux/wait.h
kernel/sched/wait.c
net/sunrpc/sched.c