summaryrefslogtreecommitdiff
path: root/fs/xfs/xfs_super.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2024-04-22 14:20:12 +0300
committerChandan Babu R <chandanbabu@kernel.org>2024-04-22 15:30:47 +0300
commitf30f656e25eb72c4309e76b16fa45062e183a2ee (patch)
treeb097332fb140ac64fbaa8f7a0d5a66358e8c83e2 /fs/xfs/xfs_super.c
parent5e1e4d4fc79c6e5f80864860208ceae27dead8a2 (diff)
downloadlinux-f30f656e25eb72c4309e76b16fa45062e183a2ee.tar.xz
xfs: split xfs_mod_freecounter
xfs_mod_freecounter has two entirely separate code paths for adding or subtracting from the free counters. Only the subtract case looks at the rsvd flag and can return an error. Split xfs_mod_freecounter into separate helpers for subtracting or adding the freecounter, and remove all the impossible to reach error handling for the addition case. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org> Signed-off-by: Chandan Babu R <chandanbabu@kernel.org>
Diffstat (limited to 'fs/xfs/xfs_super.c')
-rw-r--r--fs/xfs/xfs_super.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index 02c1a4aeaa4c..ed4a2f8c1936 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs/xfs_super.c
@@ -1882,11 +1882,7 @@ xfs_remount_ro(
xfs_inodegc_stop(mp);
/* Free the per-AG metadata reservation pool. */
- error = xfs_fs_unreserve_ag_blocks(mp);
- if (error) {
- xfs_force_shutdown(mp, SHUTDOWN_CORRUPT_INCORE);
- return error;
- }
+ xfs_fs_unreserve_ag_blocks(mp);
/*
* Before we sync the metadata, we need to free up the reserve block