diff options
author | Amir Goldstein <amir73il@gmail.com> | 2023-04-23 19:02:04 +0300 |
---|---|---|
committer | Amir Goldstein <amir73il@gmail.com> | 2023-08-12 19:02:47 +0300 |
commit | 16aac5ad1fa94894b798dd522c5c3a6a0628d7f0 (patch) | |
tree | 292889602a225cba9ad4399c6d9f63a5e14e04d5 /fs/overlayfs/inode.c | |
parent | 0c71faf5a607c8744ccee702846970bdb1a8005f (diff) | |
download | linux-16aac5ad1fa94894b798dd522c5c3a6a0628d7f0.tar.gz linux-16aac5ad1fa94894b798dd522c5c3a6a0628d7f0.tar.bz2 linux-16aac5ad1fa94894b798dd522c5c3a6a0628d7f0.zip |
ovl: support encoding non-decodable file handles
When all layers support file handles, we support encoding non-decodable
file handles (a.k.a. fid) even with nfs_export=off.
When file handles do not need to be decoded, we do not need to copy up
redirected lower directories on encode, and we encode also non-indexed
upper with lower file handle, so fid will not change on copy up.
This enables reporting fanotify events with file handles on overlayfs
with default config/mount options.
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Diffstat (limited to 'fs/overlayfs/inode.c')
-rw-r--r-- | fs/overlayfs/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/overlayfs/inode.c b/fs/overlayfs/inode.c index a63e57447be9..c1c9ff62caad 100644 --- a/fs/overlayfs/inode.c +++ b/fs/overlayfs/inode.c @@ -1311,7 +1311,7 @@ static bool ovl_hash_bylower(struct super_block *sb, struct dentry *upper, return false; /* No, if non-indexed upper with NFS export */ - if (sb->s_export_op && upper) + if (ofs->config.nfs_export && upper) return false; /* Otherwise, hash by lower inode for fsnotify */ |