From a2830da7c02a54b63963743b53191adcb440b451 Mon Sep 17 00:00:00 2001 From: Sergio Lopez Date: Wed, 8 Apr 2020 11:31:28 +0200 Subject: [PATCH] vhost_user_fs: Add the CACHE_SYMLINKS flag Add the CACHE_SYMLINKS flag, corresponding to FUSE_CACHE_SYMLINKS introduced in FUSE 7.28. Signed-off-by: Sergio Lopez --- vhost_user_fs/src/fuse.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/vhost_user_fs/src/fuse.rs b/vhost_user_fs/src/fuse.rs index 9e86fc325..088458c87 100644 --- a/vhost_user_fs/src/fuse.rs +++ b/vhost_user_fs/src/fuse.rs @@ -140,6 +140,9 @@ const ABORT_ERROR: u32 = 2_097_152; /// Init_out.max_pages contains the max number of req pages. const MAX_PAGES: u32 = 4_194_304; +/// Cache READLINK responses +const CACHE_SYMLINKS: u32 = 8_388_608; + bitflags! { /// A bitfield passed in as a parameter to and returned from the `init` method of the /// `FileSystem` trait. @@ -320,6 +323,11 @@ bitflags! { /// /// This feature is enabled by default if supported by the kernel. const MAX_PAGES = MAX_PAGES; + + /// Indicates that the kernel supports caching READLINK responses. + /// + /// This feature is not currently supported. + const CACHE_SYMLINKS = CACHE_SYMLINKS; } }