Current implementation requires traversing various queues to find
requests that need to be killed. This approach is problematic because:

1. Requests can move between different queues during their lifecycle
2. Special care must be taken when moving requests between queues to
   avoid missing requests that need to be killed.
3. The current implementation is complex, bug-prone, and difficult to
   maintain

This patch series implements a cleaner solution by introducing a dedicated
queue to track all killable requests. Each request is enqueued when created
and dequeued only when destroyed, ensuring that no requests are missed
during kill operations.

Key changes:
- Add a new killable requests queue to track all requests that can be
  killed
- Simplify kill operations by iterating only through the dedicated queue
- Remove complex queue traversal logic and race condition handling
- Improve code maintainability and reduce bug potential

Implements #VSTOR-101450
https://virtuozzo.atlassian.net/browse/VSTOR-101450

Liu Kui (7):
  fs/fuse: revamp the struct fuse_args;
  fs/fuse: revamp fuse_invalidate_files()
  fs/fuse: remove fuse_kill_requests()
  fs/fuse: remove useless code related to fuse_kill_requests
  fs/fuse: remove special treatment to killed requests
  fs/fuse: refactor fuse_file_fail_immediately()
  Revert "fs/fuse/kio: keep kio requests on revoke list at all times"

 fs/fuse/dev.c                      | 53 +++--------------
 fs/fuse/file.c                     | 69 +++++++++++++++++----
 fs/fuse/fuse_i.h                   | 34 ++++-------
 fs/fuse/inode.c                    | 96 ++----------------------------
 fs/fuse/kio/pcs/pcs_fuse_kdirect.c | 69 ++++-----------------
 fs/fuse/kio/pcs/pcs_krpc.c         |  2 +-
 6 files changed, 99 insertions(+), 224 deletions(-)

-- 
2.39.5 (Apple Git-154)

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to