/[base]
ViewVC logotype

Revision 346339


Jump to revision: Previous Next
Author: asomers
Date: Wed Apr 17 23:32:38 2019 UTC (5 years, 2 months ago)
Changed paths: 6
Log Message:
fusefs: WIP making FUSE operations interruptible

The fuse protocol includes a FUSE_INTERRUPT operation that the client can
send to the server to indicate that it wants to abort an in-progress
operation.  It's required to interrupt any syscall that is blocking on a
fuse operation.

This commit adds basic FUSE_INTERRUPT support.  If a process receives any
signal while it's blocking on a FUSE operation, it will send a
FUSE_INTERRUPT and wait for the original operation to complete.  But there
is still much to do:

* The current code will leak memory if the server ignores FUSE_INTERRUPT,
  which many do.  It will also leak memory if the server completes the
  original operation before it receives the FUSE_INTERRUPT.
* An interrupted read(2) will incorrectly appear to be successful.
* fusefs should return immediately for fatal signals.
* Operations that haven't been sent to the server yet should be aborted
  without sending FUSE_INTERRUPT.
* Test coverage should be better.
* It would be great if write operations could be made restartable.
  That would require delaying uiomove until the last possible moment, which
  would be sometime during fuse_device_read.

PR:		236530
Sponsored by:	The FreeBSD Foundation


Changed paths

Path Details
Directoryprojects/fuse2/sys/fs/fuse/fuse_device.c modified , text changed
Directoryprojects/fuse2/sys/fs/fuse/fuse_io.c modified , text changed
Directoryprojects/fuse2/sys/fs/fuse/fuse_ipc.c modified , text changed
Directoryprojects/fuse2/sys/fs/fuse/fuse_ipc.h modified , text changed
Directoryprojects/fuse2/tests/sys/fs/fusefs/interrupt.cc modified , text changed
Directoryprojects/fuse2/tests/sys/fs/fusefs/mockfs.cc modified , text changed

  ViewVC Help
Powered by ViewVC 1.1.27