diff options
author | Eric Biggers <ebiggers@google.com> | 2019-10-29 21:41:40 +0100 |
---|---|---|
committer | Eric Biggers <ebiggers@google.com> | 2019-11-13 21:15:34 +0100 |
commit | 924e319416e3b5438e4587b7c3b9d64443e825f5 (patch) | |
tree | c07bfb207ad5abcaee92c056783632184df7be75 /fs/f2fs | |
parent | ext4: support STATX_ATTR_VERITY (diff) | |
download | linux-924e319416e3b5438e4587b7c3b9d64443e825f5.tar.xz linux-924e319416e3b5438e4587b7c3b9d64443e825f5.zip |
f2fs: support STATX_ATTR_VERITY
Set the STATX_ATTR_VERITY bit when the statx() system call is used on a
verity file on f2fs.
Signed-off-by: Eric Biggers <ebiggers@google.com>
Diffstat (limited to 'fs/f2fs')
-rw-r--r-- | fs/f2fs/file.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c index 29bc0a542759..6a2e5b7d8fc7 100644 --- a/fs/f2fs/file.c +++ b/fs/f2fs/file.c @@ -726,11 +726,14 @@ int f2fs_getattr(const struct path *path, struct kstat *stat, stat->attributes |= STATX_ATTR_IMMUTABLE; if (flags & F2FS_NODUMP_FL) stat->attributes |= STATX_ATTR_NODUMP; + if (IS_VERITY(inode)) + stat->attributes |= STATX_ATTR_VERITY; stat->attributes_mask |= (STATX_ATTR_APPEND | STATX_ATTR_ENCRYPTED | STATX_ATTR_IMMUTABLE | - STATX_ATTR_NODUMP); + STATX_ATTR_NODUMP | + STATX_ATTR_VERITY); generic_fillattr(inode, stat); |