aboutsummaryrefslogtreecommitdiff
path: root/fs/xfs/xfs_rtalloc.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2024-08-30 15:36:50 -0700
committerDarrick J. Wong <djwong@kernel.org>2024-09-01 08:58:19 -0700
commit021d9c107e29a598e51fb66a54b22e5416125408 (patch)
treea7062c37a8aa20a57ec50bb6237843786bef4cc0 /fs/xfs/xfs_rtalloc.c
parent390b4775d6787706b1846f15623a68e576ec900c (diff)
xfs: remove xfs_validate_rtextents
Replace xfs_validate_rtextents with an open coded check for 0 rtextents. The name for the function implies it does a lot more than a zero check, which is more obvious when open coded. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Diffstat (limited to 'fs/xfs/xfs_rtalloc.c')
-rw-r--r--fs/xfs/xfs_rtalloc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/xfs/xfs_rtalloc.c b/fs/xfs/xfs_rtalloc.c
index ebeab8e4dab1..d28395abdd02 100644
--- a/fs/xfs/xfs_rtalloc.c
+++ b/fs/xfs/xfs_rtalloc.c
@@ -903,7 +903,7 @@ xfs_growfs_rt(
*/
nrextents = nrblocks;
do_div(nrextents, in->extsize);
- if (!xfs_validate_rtextents(nrextents)) {
+ if (nrextents == 0) {
error = -EINVAL;
goto out_unlock;
}