Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions connection.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ func (c *Connection) Init() error {
cacheSymlinks := initOp.Flags&fusekernel.InitCacheSymlinks > 0
noOpenSupport := initOp.Flags&fusekernel.InitNoOpenSupport > 0
noOpendirSupport := initOp.Flags&fusekernel.InitNoOpendirSupport > 0
asyncDIO := initOp.Flags&fusekernel.InitAsyncDIO > 0

// Respond to the init op.
initOp.Library = c.protocol
Expand All @@ -183,6 +184,10 @@ func (c *Connection) Init() error {
initOp.Flags |= fusekernel.InitAsyncRead
}

if c.cfg.EnableAsyncDIO && asyncDIO {
initOp.Flags |= fusekernel.InitAsyncDIO
}

// kernel 4.20 increases the max from 32 -> 256
initOp.Flags |= fusekernel.InitMaxPages

Expand Down
6 changes: 4 additions & 2 deletions mount_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -188,10 +188,12 @@ type MountConfig struct {
// If not set, /proc/mounts will show the filesystem type as fuse/fuseblk.
Subtype string

// Flag to enable async reads that are received from
// the kernel
// Flag to enable async buffered reads
EnableAsyncReads bool

// Flag to enable async direct IO
EnableAsyncDIO bool

// Flag to enable parallel lookup and readdir operations from the
// kernel
// Ref: https://github.com/torvalds/linux/commit/5c672ab3f0ee0f78f7acad183f34db0f8781a200
Expand Down
Loading