Commit c56c9e20 authored by Kirill Smelkov's avatar Kirill Smelkov Committed by Han-Wen Nienhuys

fuse: Add CAP_{ABORT_ERROR,MAX_PAGES,CACHE_SYMLINKS,NO_OPENDIR_SUPPORT}

The first 3 are present since

CAP_ABORT_ERROR is present since Linux 4.17:

	https://git.kernel.org/linus/3b7008b226

CAP_MAX_PAGES & CAP_CACHE_SYMLINKS are present since Linux 4.20:

	https://git.kernel.org/linus/5da784cce4
	https://git.kernel.org/linus/5571f1e654

CAP_NO_OPENDIR_SUPPORT will be present in Linux 5.1:

	https://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git/commit?id=d9a9ea94f7
parent afd12f37
...@@ -28,27 +28,31 @@ func init() { ...@@ -28,27 +28,31 @@ func init() {
READ_LOCKOWNER: "LOCKOWNER", READ_LOCKOWNER: "LOCKOWNER",
} }
initFlagNames = map[int64]string{ initFlagNames = map[int64]string{
CAP_ASYNC_READ: "ASYNC_READ", CAP_ASYNC_READ: "ASYNC_READ",
CAP_POSIX_LOCKS: "POSIX_LOCKS", CAP_POSIX_LOCKS: "POSIX_LOCKS",
CAP_FILE_OPS: "FILE_OPS", CAP_FILE_OPS: "FILE_OPS",
CAP_ATOMIC_O_TRUNC: "ATOMIC_O_TRUNC", CAP_ATOMIC_O_TRUNC: "ATOMIC_O_TRUNC",
CAP_EXPORT_SUPPORT: "EXPORT_SUPPORT", CAP_EXPORT_SUPPORT: "EXPORT_SUPPORT",
CAP_BIG_WRITES: "BIG_WRITES", CAP_BIG_WRITES: "BIG_WRITES",
CAP_DONT_MASK: "DONT_MASK", CAP_DONT_MASK: "DONT_MASK",
CAP_SPLICE_WRITE: "SPLICE_WRITE", CAP_SPLICE_WRITE: "SPLICE_WRITE",
CAP_SPLICE_MOVE: "SPLICE_MOVE", CAP_SPLICE_MOVE: "SPLICE_MOVE",
CAP_SPLICE_READ: "SPLICE_READ", CAP_SPLICE_READ: "SPLICE_READ",
CAP_FLOCK_LOCKS: "FLOCK_LOCKS", CAP_FLOCK_LOCKS: "FLOCK_LOCKS",
CAP_IOCTL_DIR: "IOCTL_DIR", CAP_IOCTL_DIR: "IOCTL_DIR",
CAP_AUTO_INVAL_DATA: "AUTO_INVAL_DATA", CAP_AUTO_INVAL_DATA: "AUTO_INVAL_DATA",
CAP_READDIRPLUS: "READDIRPLUS", CAP_READDIRPLUS: "READDIRPLUS",
CAP_READDIRPLUS_AUTO: "READDIRPLUS_AUTO", CAP_READDIRPLUS_AUTO: "READDIRPLUS_AUTO",
CAP_ASYNC_DIO: "ASYNC_DIO", CAP_ASYNC_DIO: "ASYNC_DIO",
CAP_WRITEBACK_CACHE: "WRITEBACK_CACHE", CAP_WRITEBACK_CACHE: "WRITEBACK_CACHE",
CAP_NO_OPEN_SUPPORT: "NO_OPEN_SUPPORT", CAP_NO_OPEN_SUPPORT: "NO_OPEN_SUPPORT",
CAP_PARALLEL_DIROPS: "PARALLEL_DIROPS", CAP_PARALLEL_DIROPS: "PARALLEL_DIROPS",
CAP_POSIX_ACL: "POSIX_ACL", CAP_POSIX_ACL: "POSIX_ACL",
CAP_HANDLE_KILLPRIV: "HANDLE_KILLPRIV", CAP_HANDLE_KILLPRIV: "HANDLE_KILLPRIV",
CAP_ABORT_ERROR: "ABORT_ERROR",
CAP_MAX_PAGES: "MAX_PAGES",
CAP_CACHE_SYMLINKS: "CACHE_SYMLINKS",
CAP_NO_OPENDIR_SUPPORT: "NO_OPENDIR_SUPPORT",
} }
releaseFlagNames = map[int64]string{ releaseFlagNames = map[int64]string{
RELEASE_FLUSH: "FLUSH", RELEASE_FLUSH: "FLUSH",
......
...@@ -257,27 +257,31 @@ type OpenOut struct { ...@@ -257,27 +257,31 @@ type OpenOut struct {
// To be set in InitIn/InitOut.Flags. // To be set in InitIn/InitOut.Flags.
const ( const (
CAP_ASYNC_READ = (1 << 0) CAP_ASYNC_READ = (1 << 0)
CAP_POSIX_LOCKS = (1 << 1) CAP_POSIX_LOCKS = (1 << 1)
CAP_FILE_OPS = (1 << 2) CAP_FILE_OPS = (1 << 2)
CAP_ATOMIC_O_TRUNC = (1 << 3) CAP_ATOMIC_O_TRUNC = (1 << 3)
CAP_EXPORT_SUPPORT = (1 << 4) CAP_EXPORT_SUPPORT = (1 << 4)
CAP_BIG_WRITES = (1 << 5) CAP_BIG_WRITES = (1 << 5)
CAP_DONT_MASK = (1 << 6) CAP_DONT_MASK = (1 << 6)
CAP_SPLICE_WRITE = (1 << 7) CAP_SPLICE_WRITE = (1 << 7)
CAP_SPLICE_MOVE = (1 << 8) CAP_SPLICE_MOVE = (1 << 8)
CAP_SPLICE_READ = (1 << 9) CAP_SPLICE_READ = (1 << 9)
CAP_FLOCK_LOCKS = (1 << 10) CAP_FLOCK_LOCKS = (1 << 10)
CAP_IOCTL_DIR = (1 << 11) CAP_IOCTL_DIR = (1 << 11)
CAP_AUTO_INVAL_DATA = (1 << 12) CAP_AUTO_INVAL_DATA = (1 << 12)
CAP_READDIRPLUS = (1 << 13) CAP_READDIRPLUS = (1 << 13)
CAP_READDIRPLUS_AUTO = (1 << 14) CAP_READDIRPLUS_AUTO = (1 << 14)
CAP_ASYNC_DIO = (1 << 15) CAP_ASYNC_DIO = (1 << 15)
CAP_WRITEBACK_CACHE = (1 << 16) CAP_WRITEBACK_CACHE = (1 << 16)
CAP_NO_OPEN_SUPPORT = (1 << 17) CAP_NO_OPEN_SUPPORT = (1 << 17)
CAP_PARALLEL_DIROPS = (1 << 18) CAP_PARALLEL_DIROPS = (1 << 18)
CAP_HANDLE_KILLPRIV = (1 << 19) CAP_HANDLE_KILLPRIV = (1 << 19)
CAP_POSIX_ACL = (1 << 20) CAP_POSIX_ACL = (1 << 20)
CAP_ABORT_ERROR = (1 << 21)
CAP_MAX_PAGES = (1 << 22)
CAP_CACHE_SYMLINKS = (1 << 23)
CAP_NO_OPENDIR_SUPPORT = (1 << 24)
) )
type InitIn struct { type InitIn struct {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment