summaryrefslogtreecommitdiff
path: root/fs/cifs/transport.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2017-01-31 17:24:03 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-05-08 08:49:42 +0300
commit43c1696e5e91dc946325c2968c29e60423659abc (patch)
tree92aae46072dae98b9d806b6b9ea0c4147fbf931d /fs/cifs/transport.c
parentd08276658dee67cc0961691578a84cd6c086aed6 (diff)
downloadlinux-43c1696e5e91dc946325c2968c29e60423659abc.tar.xz
timerfd: Protect the might cancel mechanism proper
commit 1e38da300e1e395a15048b0af1e5305bd91402f6 upstream. The handling of the might_cancel queueing is not properly protected, so parallel operations on the file descriptor can race with each other and lead to list corruptions or use after free. Protect the context for these operations with a seperate lock. The wait queue lock cannot be reused for this because that would create a lock inversion scenario vs. the cancel lock. Replacing might_cancel with an atomic (atomic_t or atomic bit) does not help either because it still can race vs. the actual list operation. Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: "linux-fsdevel@vger.kernel.org" Cc: syzkaller <syzkaller@googlegroups.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: linux-fsdevel@vger.kernel.org Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1701311521430.3457@nanos Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/cifs/transport.c')
0 files changed, 0 insertions, 0 deletions