fuse: {io-uring} Prevent mount point hang on fuse-server termination
authorBernd Schubert <bschubert@ddn.com>
Mon, 20 Jan 2025 01:29:08 +0000 (02:29 +0100)
committerMiklos Szeredi <mszeredi@redhat.com>
Mon, 27 Jan 2025 17:02:21 +0000 (18:02 +0100)
commitb6236c8407cba5d7a108facb1bcfab24994d3814
tree5bf20d18b72a5cc01e9d7e6237fa50f9a5d8fa02
parent857b0263f30eebe13ab4b6a65156a0d6c8fc2210
fuse: {io-uring} Prevent mount point hang on fuse-server termination

When the fuse-server terminates while the fuse-client or kernel
still has queued URING_CMDs, these commands retain references
to the struct file used by the fuse connection. This prevents
fuse_dev_release() from being invoked, resulting in a hung mount
point.

This patch addresses the issue by making queued URING_CMDs
cancelable, allowing fuse_dev_release() to proceed as expected
and preventing the mount point from hanging.

Signed-off-by: Bernd Schubert <bschubert@ddn.com>
Reviewed-by: Pavel Begunkov <asml.silence@gmail.com> # io_uring
Reviewed-by: Luis Henriques <luis@igalia.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
fs/fuse/dev_uring.c
fs/fuse/dev_uring_i.h