From: "Darrick J. Wong" <[email protected]>

Advertise that this filesystem supports fsverity.

Signed-off-by: Darrick J. Wong <[email protected]>
Reviewed-by: Andrey Albershteyn <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Andrey Albershteyn <[email protected]>
---
 fs/xfs/libxfs/xfs_fs.h | 1 +
 fs/xfs/libxfs/xfs_sb.c | 2 ++
 2 files changed, 3 insertions(+)

diff --git a/fs/xfs/libxfs/xfs_fs.h b/fs/xfs/libxfs/xfs_fs.h
index d165de607d17..ebf17a0b0722 100644
--- a/fs/xfs/libxfs/xfs_fs.h
+++ b/fs/xfs/libxfs/xfs_fs.h
@@ -250,6 +250,7 @@ typedef struct xfs_fsop_resblks {
 #define XFS_FSOP_GEOM_FLAGS_PARENT     (1 << 25) /* linux parent pointers */
 #define XFS_FSOP_GEOM_FLAGS_METADIR    (1 << 26) /* metadata directories */
 #define XFS_FSOP_GEOM_FLAGS_ZONED      (1 << 27) /* zoned rt device */
+#define XFS_FSOP_GEOM_FLAGS_VERITY     (1 << 28) /* fs-verity */
 
 /*
  * Minimum and maximum sizes need for growth checks.
diff --git a/fs/xfs/libxfs/xfs_sb.c b/fs/xfs/libxfs/xfs_sb.c
index a15510ebd2f1..222bbe5559df 100644
--- a/fs/xfs/libxfs/xfs_sb.c
+++ b/fs/xfs/libxfs/xfs_sb.c
@@ -1590,6 +1590,8 @@ xfs_fs_geometry(
                geo->flags |= XFS_FSOP_GEOM_FLAGS_METADIR;
        if (xfs_has_zoned(mp))
                geo->flags |= XFS_FSOP_GEOM_FLAGS_ZONED;
+       if (xfs_has_verity(mp))
+               geo->flags |= XFS_FSOP_GEOM_FLAGS_VERITY;
        geo->rtsectsize = sbp->sb_blocksize;
        geo->dirblocksize = xfs_dir2_dirblock_bytes(sbp);
 
-- 
2.51.2



_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Reply via email to