From: Jonathan Corbet Date: Fri, 5 Dec 2008 23:12:48 +0000 (-0700) Subject: Fix a race condition in FASYNC handling X-Git-Tag: v2.6.28-rc8~45 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=218d11a8b071b23b76c484fd5f72a4fe3306801e;p=pandora-kernel.git Fix a race condition in FASYNC handling Changeset a238b790d5f99c7832f9b73ac8847025815b85f7 (Call fasync() functions without the BKL) introduced a race which could leave file->f_flags in a state inconsistent with what the underlying driver/filesystem believes. Revert that change, and also fix the same races in ioctl_fioasync() and ioctl_fionbio(). This is a minimal, short-term fix; the real fix will not involve the BKL. Reported-by: Oleg Nesterov Cc: Andi Kleen Cc: Al Viro Cc: stable@kernel.org Signed-off-by: Jonathan Corbet Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed