fuse: umount should wait for all requests
fuse_abort_conn() does not guarantee that all async requests have actually
finished aborting (i.e. their ->end() function is called). This could
actually result in still used inodes after umount.
Add a helper to wait until all requests are fully done. This is done by
looking at the "num_waiting" counter. When this counter drops to zero, we
can be sure that no more requests are outstanding.
Fixes: 0d8e84b043
("fuse: simplify request abort")
Cc: <stable@vger.kernel.org> # v4.2
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
This commit is contained in:
@@ -394,6 +394,8 @@ static void fuse_put_super(struct super_block *sb)
|
||||
fuse_send_destroy(fc);
|
||||
|
||||
fuse_abort_conn(fc, false);
|
||||
fuse_wait_aborted(fc);
|
||||
|
||||
mutex_lock(&fuse_mutex);
|
||||
list_del(&fc->entry);
|
||||
fuse_ctl_remove_conn(fc);
|
||||
|
Reference in New Issue
Block a user