diff mbox series

[11/12] btrfs: const-ify fs_info for the compat flag handlers

Message ID df937c197eae36770e2cb47a32339da7eddb3d48.1646692306.git.josef@toxicpanda.com (mailing list archive)
State New, archived
Headers show
Series btrfs: item helper prep work for snapshot_id | expand

Commit Message

Josef Bacik March 7, 2022, 10:33 p.m. UTC
We don't modify fs_info here, use const.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
---
 fs/btrfs/ctree.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index 8187e8ec457a..ec77871ad839 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -1796,7 +1796,7 @@  BTRFS_SETGET_STACK_FUNCS(super_nr_global_roots, struct btrfs_super_block,
 #define btrfs_fs_incompat(fs_info, opt) \
 	__btrfs_fs_incompat((fs_info), BTRFS_FEATURE_INCOMPAT_##opt)
 
-static inline bool __btrfs_fs_incompat(struct btrfs_fs_info *fs_info, u64 flag)
+static inline bool __btrfs_fs_incompat(const struct btrfs_fs_info *fs_info, u64 flag)
 {
 	struct btrfs_super_block *disk_super;
 	disk_super = fs_info->super_copy;
@@ -1806,7 +1806,7 @@  static inline bool __btrfs_fs_incompat(struct btrfs_fs_info *fs_info, u64 flag)
 #define btrfs_fs_compat_ro(fs_info, opt) \
 	__btrfs_fs_compat_ro((fs_info), BTRFS_FEATURE_COMPAT_RO_##opt)
 
-static inline int __btrfs_fs_compat_ro(struct btrfs_fs_info *fs_info, u64 flag)
+static inline int __btrfs_fs_compat_ro(const struct btrfs_fs_info *fs_info, u64 flag)
 {
 	struct btrfs_super_block *disk_super;
 	disk_super = fs_info->super_copy;