From: Darrick J. Wong Date: Mon, 29 Jul 2024 23:23:12 +0000 (-0700) Subject: xfs_scrub: collapse trim_filesystem X-Git-Tag: v6.10.0~14^2~4 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=5935bcabee648d4076dedf49ed184e5906daf80e;p=xfsprogs-dev.git xfs_scrub: collapse trim_filesystem Collapse this two-line helper into the main function since it's trivial. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- diff --git a/scrub/phase8.c b/scrub/phase8.c index 07726b5b8..e577260a9 100644 --- a/scrub/phase8.c +++ b/scrub/phase8.c @@ -21,15 +21,6 @@ /* Phase 8: Trim filesystem. */ -/* Trim the unused areas of the filesystem if the caller asked us to. */ -static void -trim_filesystem( - struct scrub_ctx *ctx) -{ - fstrim(ctx); - progress_add(1); -} - /* Trim the filesystem, if desired. */ int phase8_func( @@ -47,7 +38,8 @@ phase8_func( return 0; maybe_trim: - trim_filesystem(ctx); + fstrim(ctx); + progress_add(1); return 0; }