Add a flag to entry expiration that lets the filesystem expire a dentry without kicking it out from the cache immediately. This makes a difference for overmounted dentries, where plain invalidation would detach all submounts before dropping the dentry from the cache. If only expiry is set on the dentry, then any overmounts are left alone and until ->d_revalidate() is called. Note: ->d_revalidate() is not called for the case of following a submount, so invalidation will only be triggered for the non-overmounted case. The dentry could also be mounted in a different mount instance, in which case any submounts will still be detached.
Showing the changes to include/uapi (1 of 4 files). Show all
Unified · Split
| @@ -197,6 +197,9 @@ · 196 unmodified lines | ||
| 197 | 197 | * |
| 198 | 198 | * 7.37 |
| 199 | 199 | * - add FUSE_TMPFILE |
| 200 | + * | |
| 201 | + * 7.38 | |
| 202 | + * - add FUSE_EXPIRE_ONLY flag to fuse_notify_inval_entry | |
| 200 | 203 | */ |
| 201 | 204 | |
| 202 | 205 | #ifndef _LINUX_FUSE_H |
| @@ -232,7 +235,7 @@ · 29 unmodified lines | ||
| 232 | 235 | #define FUSE_KERNEL_VERSION 7 |
| 233 | 236 | |
| 234 | 237 | /** Minor version number of this interface */ |
| 235 | −#define FUSE_KERNEL_MINOR_VERSION 37 | |
| 238 | +#define FUSE_KERNEL_MINOR_VERSION 38 | |
| 236 | 239 | |
| 237 | 240 | /** The node ID of the root inode */ |
| 238 | 241 | #define FUSE_ROOT_ID 1 |
| @@ -491,6 +494,12 @@ struct fuse_file_lock { · 252 unmodified lines | ||
| 491 | 494 | */ |
| 492 | 495 | #define FUSE_SETXATTR_ACL_KILL_SGID (1 << 0) |
| 493 | 496 | |
| 497 | +/** | |
| 498 | + * notify_inval_entry flags | |
| 499 | + * FUSE_EXPIRE_ONLY | |
| 500 | + */ | |
| 501 | +#define FUSE_EXPIRE_ONLY (1 << 0) | |
| 502 | + | |
| 494 | 503 | enum fuse_opcode { |
| 495 | 504 | FUSE_LOOKUP = 1, |
| 496 | 505 | FUSE_FORGET = 2, /* no reply */ |
| @@ -919,7 +928,7 @@ struct fuse_notify_inval_inode_out { · 422 unmodified lines | ||
| 919 | 928 | struct fuse_notify_inval_entry_out { |
| 920 | 929 | uint64_t parent; |
| 921 | 930 | uint32_t namelen; |
| 922 | − uint32_t padding; | |
| 931 | + uint32_t flags; | |
| 923 | 932 | }; |
| 924 | 933 | |
| 925 | 934 | struct fuse_notify_delete_out { |