summaryrefslogtreecommitdiffstats
path: root/fs/xfs/libxfs/xfs_inode_fork.c
diff options
context:
space:
mode:
authorChandan Babu R <chandan.babu@oracle.com>2021-11-16 09:54:37 +0000
committerChandan Babu R <chandan.babu@oracle.com>2022-04-11 04:11:19 +0000
commitdf9ad5cc7a524048ea7ff983d6feeb6d8c47a761 (patch)
tree770a196d7b4b5c9607d81e7f8103676e57f6efc6 /fs/xfs/libxfs/xfs_inode_fork.c
parent0c35e7ba18508e9344a1f27b412924bc8b34eba8 (diff)
downloadlinux-df9ad5cc7a524048ea7ff983d6feeb6d8c47a761.tar.bz2
xfs: Introduce macros to represent new maximum extent counts for data/attr forks
This commit defines new macros to represent maximum extent counts allowed by filesystems which have support for large per-inode extent counters. Reviewed-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Chandan Babu R <chandan.babu@oracle.com>
Diffstat (limited to 'fs/xfs/libxfs/xfs_inode_fork.c')
-rw-r--r--fs/xfs/libxfs/xfs_inode_fork.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/xfs/libxfs/xfs_inode_fork.c b/fs/xfs/libxfs/xfs_inode_fork.c
index 004b205d87b8..bb5d841aac58 100644
--- a/fs/xfs/libxfs/xfs_inode_fork.c
+++ b/fs/xfs/libxfs/xfs_inode_fork.c
@@ -744,7 +744,8 @@ xfs_iext_count_may_overflow(
if (whichfork == XFS_COW_FORK)
return 0;
- max_exts = xfs_iext_max_nextents(whichfork);
+ max_exts = xfs_iext_max_nextents(xfs_inode_has_large_extent_counts(ip),
+ whichfork);
if (XFS_TEST_ERROR(false, ip->i_mount, XFS_ERRTAG_REDUCE_MAX_IEXTENTS))
max_exts = 10;