aboutsummaryrefslogtreecommitdiff
path: root/test/fuse_integration/directio_linux.go
blob: 862146f9dc60dd4a03ce3e4fb871f95d3dc011f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
//go:build linux

package fuse

import (
	"syscall"
)

// Direct I/O support for Linux

const (
	O_DIRECT = 0x4000 // Direct I/O flag for Linux
)

func openDirectIO(path string, flags int, mode uint32) (int, error) {
	return syscall.Open(path, flags|O_DIRECT, mode)
}

func isDirectIOSupported() bool {
	return true
}