fuse: fix hang of single threaded fuseblk filesystem
commit9efe56738fecd591b5bf366a325440f9b457ebd6
authorMiklos Szeredi <mszeredi@suse.cz>
Fri, 25 Feb 2011 13:44:58 +0000 (25 14:44 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 7 Mar 2011 23:17:53 +0000 (7 15:17 -0800)
tree031ad027934cc926551adf991b2c9f9538390e20
parentbf30c46aba4aecb1a289ed3249b46e6091b6f7b2
fuse: fix hang of single threaded fuseblk filesystem

commit 5a18ec176c934ca1bc9dc61580a5e0e90a9b5733 upstream.

Single threaded NTFS-3G could get stuck if a delayed RELEASE reply
triggered a DESTROY request via path_put().

Fix this by

 a) making RELEASE requests synchronous, whenever possible, on fuseblk
 filesystems

 b) if not possible (triggered by an asynchronous read/write) then do
 the path_put() in a separate thread with schedule_work().

Reported-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/fuse/file.c
fs/fuse/fuse_i.h