diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2018-10-31 17:50:02 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-10-31 17:50:02 -0400 |
| commit | 9b5cf826ef8b607d452ba7bf683ae5510a745232 (patch) | |
| tree | 278ef54cfcb6ba86480bd9d72c1c542233908c8b /include/uapi/linux | |
| parent | 31990f0f5366a8f66688edae8688723b22034108 (diff) | |
| parent | 5571f1e65486be025f73fa6aa30fb03725d362a2 (diff) | |
Merge tag 'fuse-update-4.20' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse
Pull fuse updates from Miklos Szeredi:
"As well as the usual bug fixes, this adds the following new features:
- cached readdir and readlink
- max I/O size increased from 128k to 1M
- improved performance and scalability of request queues
- copy_file_range support
The only non-fuse bits are trivial cleanups of macros in
<linux/bitops.h>"
* tag 'fuse-update-4.20' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: (31 commits)
fuse: enable caching of symlinks
fuse: only invalidate atime in direct read
fuse: don't need GETATTR after every READ
fuse: allow fine grained attr cache invaldation
bitops: protect variables in bit_clear_unless() macro
bitops: protect variables in set_mask_bits() macro
fuse: realloc page array
fuse: add max_pages to init_out
fuse: allocate page array more efficiently
fuse: reduce size of struct fuse_inode
fuse: use iversion for readdir cache verification
fuse: use mtime for readdir cache verification
fuse: add readdir cache version
fuse: allow using readdir cache
fuse: allow caching readdir
fuse: extract fuse_emit() helper
fuse: add FOPEN_CACHE_DIR
fuse: split out readdir.c
fuse: Use hash table to link processing request
fuse: kill req->intr_unique
...
Diffstat (limited to 'include/uapi/linux')
| -rw-r--r-- | include/uapi/linux/fuse.h | 119 |
1 files changed, 72 insertions, 47 deletions
diff --git a/include/uapi/linux/fuse.h b/include/uapi/linux/fuse.h index 92fa24c24c92..b4967d48bfda 100644 --- a/include/uapi/linux/fuse.h +++ b/include/uapi/linux/fuse.h | |||
| @@ -116,6 +116,12 @@ | |||
| 116 | * | 116 | * |
| 117 | * 7.27 | 117 | * 7.27 |
| 118 | * - add FUSE_ABORT_ERROR | 118 | * - add FUSE_ABORT_ERROR |
| 119 | * | ||
| 120 | * 7.28 | ||
| 121 | * - add FUSE_COPY_FILE_RANGE | ||
| 122 | * - add FOPEN_CACHE_DIR | ||
| 123 | * - add FUSE_MAX_PAGES, add max_pages to init_out | ||
| 124 | * - add FUSE_CACHE_SYMLINKS | ||
| 119 | */ | 125 | */ |
| 120 | 126 | ||
| 121 | #ifndef _LINUX_FUSE_H | 127 | #ifndef _LINUX_FUSE_H |
| @@ -151,7 +157,7 @@ | |||
| 151 | #define FUSE_KERNEL_VERSION 7 | 157 | #define FUSE_KERNEL_VERSION 7 |
| 152 | 158 | ||
| 153 | /** Minor version number of this interface */ | 159 | /** Minor version number of this interface */ |
| 154 | #define FUSE_KERNEL_MINOR_VERSION 27 | 160 | #define FUSE_KERNEL_MINOR_VERSION 28 |
| 155 | 161 | ||
| 156 | /** The node ID of the root inode */ | 162 | /** The node ID of the root inode */ |
| 157 | #define FUSE_ROOT_ID 1 | 163 | #define FUSE_ROOT_ID 1 |
| @@ -219,10 +225,12 @@ struct fuse_file_lock { | |||
| 219 | * FOPEN_DIRECT_IO: bypass page cache for this open file | 225 | * FOPEN_DIRECT_IO: bypass page cache for this open file |
| 220 | * FOPEN_KEEP_CACHE: don't invalidate the data cache on open | 226 | * FOPEN_KEEP_CACHE: don't invalidate the data cache on open |
| 221 | * FOPEN_NONSEEKABLE: the file is not seekable | 227 | * FOPEN_NONSEEKABLE: the file is not seekable |
| 228 | * FOPEN_CACHE_DIR: allow caching this directory | ||
| 222 | */ | 229 | */ |
| 223 | #define FOPEN_DIRECT_IO (1 << 0) | 230 | #define FOPEN_DIRECT_IO (1 << 0) |
| 224 | #define FOPEN_KEEP_CACHE (1 << 1) | 231 | #define FOPEN_KEEP_CACHE (1 << 1) |
| 225 | #define FOPEN_NONSEEKABLE (1 << 2) | 232 | #define FOPEN_NONSEEKABLE (1 << 2) |
| 233 | #define FOPEN_CACHE_DIR (1 << 3) | ||
| 226 | 234 | ||
| 227 | /** | 235 | /** |
| 228 | * INIT request/reply flags | 236 | * INIT request/reply flags |
| @@ -249,6 +257,8 @@ struct fuse_file_lock { | |||
| 249 | * FUSE_HANDLE_KILLPRIV: fs handles killing suid/sgid/cap on write/chown/trunc | 257 | * FUSE_HANDLE_KILLPRIV: fs handles killing suid/sgid/cap on write/chown/trunc |
| 250 | * FUSE_POSIX_ACL: filesystem supports posix acls | 258 | * FUSE_POSIX_ACL: filesystem supports posix acls |
| 251 | * FUSE_ABORT_ERROR: reading the device after abort returns ECONNABORTED | 259 | * FUSE_ABORT_ERROR: reading the device after abort returns ECONNABORTED |
| 260 | * FUSE_MAX_PAGES: init_out.max_pages contains the max number of req pages | ||
| 261 | * FUSE_CACHE_SYMLINKS: cache READLINK responses | ||
| 252 | */ | 262 | */ |
| 253 | #define FUSE_ASYNC_READ (1 << 0) | 263 | #define FUSE_ASYNC_READ (1 << 0) |
| 254 | #define FUSE_POSIX_LOCKS (1 << 1) | 264 | #define FUSE_POSIX_LOCKS (1 << 1) |
| @@ -272,6 +282,8 @@ struct fuse_file_lock { | |||
| 272 | #define FUSE_HANDLE_KILLPRIV (1 << 19) | 282 | #define FUSE_HANDLE_KILLPRIV (1 << 19) |
| 273 | #define FUSE_POSIX_ACL (1 << 20) | 283 | #define FUSE_POSIX_ACL (1 << 20) |
| 274 | #define FUSE_ABORT_ERROR (1 << 21) | 284 | #define FUSE_ABORT_ERROR (1 << 21) |
| 285 | #define FUSE_MAX_PAGES (1 << 22) | ||
| 286 | #define FUSE_CACHE_SYMLINKS (1 << 23) | ||
| 275 | 287 | ||
| 276 | /** | 288 | /** |
| 277 | * CUSE INIT request/reply flags | 289 | * CUSE INIT request/reply flags |
| @@ -337,53 +349,54 @@ struct fuse_file_lock { | |||
| 337 | #define FUSE_POLL_SCHEDULE_NOTIFY (1 << 0) | 349 | #define FUSE_POLL_SCHEDULE_NOTIFY (1 << 0) |
| 338 | 350 | ||
| 339 | enum fuse_opcode { | 351 | enum fuse_opcode { |
| 340 | FUSE_LOOKUP = 1, | 352 | FUSE_LOOKUP = 1, |
| 341 | FUSE_FORGET = 2, /* no reply */ | 353 | FUSE_FORGET = 2, /* no reply */ |
| 342 | FUSE_GETATTR = 3, | 354 | FUSE_GETATTR = 3, |
| 343 | FUSE_SETATTR = 4, | 355 | FUSE_SETATTR = 4, |
| 344 | FUSE_READLINK = 5, | 356 | FUSE_READLINK = 5, |
| 345 | FUSE_SYMLINK = 6, | 357 | FUSE_SYMLINK = 6, |
| 346 | FUSE_MKNOD = 8, | 358 | FUSE_MKNOD = 8, |
| 347 | FUSE_MKDIR = 9, | 359 | FUSE_MKDIR = 9, |
| 348 | FUSE_UNLINK = 10, | 360 | FUSE_UNLINK = 10, |
| 349 | FUSE_RMDIR = 11, | 361 | FUSE_RMDIR = 11, |
| 350 | FUSE_RENAME = 12, | 362 | FUSE_RENAME = 12, |
| 351 | FUSE_LINK = 13, | 363 | FUSE_LINK = 13, |
| 352 | FUSE_OPEN = 14, | 364 | FUSE_OPEN = 14, |
| 353 | FUSE_READ = 15, | 365 | FUSE_READ = 15, |
| 354 | FUSE_WRITE = 16, | 366 | FUSE_WRITE = 16, |
| 355 | FUSE_STATFS = 17, | 367 | FUSE_STATFS = 17, |
| 356 | FUSE_RELEASE = 18, | 368 | FUSE_RELEASE = 18, |
| 357 | FUSE_FSYNC = 20, | 369 | FUSE_FSYNC = 20, |
| 358 | FUSE_SETXATTR = 21, | 370 | FUSE_SETXATTR = 21, |
| 359 | FUSE_GETXATTR = 22, | 371 | FUSE_GETXATTR = 22, |
| 360 | FUSE_LISTXATTR = 23, | 372 | FUSE_LISTXATTR = 23, |
| 361 | FUSE_REMOVEXATTR = 24, | 373 | FUSE_REMOVEXATTR = 24, |
| 362 | FUSE_FLUSH = 25, | 374 | FUSE_FLUSH = 25, |
| 363 | FUSE_INIT = 26, | 375 | FUSE_INIT = 26, |
| 364 | FUSE_OPENDIR = 27, | 376 | FUSE_OPENDIR = 27, |
| 365 | FUSE_READDIR = 28, | 377 | FUSE_READDIR = 28, |
| 366 | FUSE_RELEASEDIR = 29, | 378 | FUSE_RELEASEDIR = 29, |
| 367 | FUSE_FSYNCDIR = 30, | 379 | FUSE_FSYNCDIR = 30, |
| 368 | FUSE_GETLK = 31, | 380 | FUSE_GETLK = 31, |
| 369 | FUSE_SETLK = 32, | 381 | FUSE_SETLK = 32, |
| 370 | FUSE_SETLKW = 33, | 382 | FUSE_SETLKW = 33, |
| 371 | FUSE_ACCESS = 34, | 383 | FUSE_ACCESS = 34, |
| 372 | FUSE_CREATE = 35, | 384 | FUSE_CREATE = 35, |
| 373 | FUSE_INTERRUPT = 36, | 385 | FUSE_INTERRUPT = 36, |
| 374 | FUSE_BMAP = 37, | 386 | FUSE_BMAP = 37, |
| 375 | FUSE_DESTROY = 38, | 387 | FUSE_DESTROY = 38, |
| 376 | FUSE_IOCTL = 39, | 388 | FUSE_IOCTL = 39, |
| 377 | FUSE_POLL = 40, | 389 | FUSE_POLL = 40, |
| 378 | FUSE_NOTIFY_REPLY = 41, | 390 | FUSE_NOTIFY_REPLY = 41, |
| 379 | FUSE_BATCH_FORGET = 42, | 391 | FUSE_BATCH_FORGET = 42, |
| 380 | FUSE_FALLOCATE = 43, | 392 | FUSE_FALLOCATE = 43, |
| 381 | FUSE_READDIRPLUS = 44, | 393 | FUSE_READDIRPLUS = 44, |
| 382 | FUSE_RENAME2 = 45, | 394 | FUSE_RENAME2 = 45, |
| 383 | FUSE_LSEEK = 46, | 395 | FUSE_LSEEK = 46, |
| 396 | FUSE_COPY_FILE_RANGE = 47, | ||
| 384 | 397 | ||
| 385 | /* CUSE specific operations */ | 398 | /* CUSE specific operations */ |
| 386 | CUSE_INIT = 4096, | 399 | CUSE_INIT = 4096, |
| 387 | }; | 400 | }; |
| 388 | 401 | ||
| 389 | enum fuse_notify_code { | 402 | enum fuse_notify_code { |
| @@ -610,7 +623,9 @@ struct fuse_init_out { | |||
| 610 | uint16_t congestion_threshold; | 623 | uint16_t congestion_threshold; |
| 611 | uint32_t max_write; | 624 | uint32_t max_write; |
| 612 | uint32_t time_gran; | 625 | uint32_t time_gran; |
| 613 | uint32_t unused[9]; | 626 | uint16_t max_pages; |
| 627 | uint16_t padding; | ||
| 628 | uint32_t unused[8]; | ||
| 614 | }; | 629 | }; |
| 615 | 630 | ||
| 616 | #define CUSE_INIT_INFO_MAX 4096 | 631 | #define CUSE_INIT_INFO_MAX 4096 |
| @@ -792,4 +807,14 @@ struct fuse_lseek_out { | |||
| 792 | uint64_t offset; | 807 | uint64_t offset; |
| 793 | }; | 808 | }; |
| 794 | 809 | ||
| 810 | struct fuse_copy_file_range_in { | ||
| 811 | uint64_t fh_in; | ||
| 812 | uint64_t off_in; | ||
| 813 | uint64_t nodeid_out; | ||
| 814 | uint64_t fh_out; | ||
| 815 | uint64_t off_out; | ||
| 816 | uint64_t len; | ||
| 817 | uint64_t flags; | ||
| 818 | }; | ||
| 819 | |||
| 795 | #endif /* _LINUX_FUSE_H */ | 820 | #endif /* _LINUX_FUSE_H */ |
