diff options
author | Christoph Hellwig <hch@lst.de> | 2024-07-02 11:22:51 -0700 |
---|---|---|
committer | Darrick J. Wong <djwong@kernel.org> | 2024-07-02 11:37:01 -0700 |
commit | 62d597a197e390a89eadff60b98231e91b32ab83 (patch) | |
tree | d254459819a49e3f00f9766b5681c85891bae207 /fs/xfs/xfs_drain.c | |
parent | 980faece91a60c279e7c24cb1d1a378bbbb74bb9 (diff) |
xfs: pass the fsbno to xfs_perag_intent_get
All callers of xfs_perag_intent_get have a fsbno and need boilerplate
code to turn that into an agno. Just pass the fsbno to
xfs_perag_intent_get and look up the agno there.
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_drain.c')
-rw-r--r-- | fs/xfs/xfs_drain.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/xfs/xfs_drain.c b/fs/xfs/xfs_drain.c index 005a66be44a2..7bdb9688c0f5 100644 --- a/fs/xfs/xfs_drain.c +++ b/fs/xfs/xfs_drain.c @@ -94,17 +94,17 @@ static inline int xfs_defer_drain_wait(struct xfs_defer_drain *dr) } /* - * Get a passive reference to an AG and declare an intent to update its - * metadata. + * Get a passive reference to the AG that contains a fsbno and declare an intent + * to update its metadata. */ struct xfs_perag * xfs_perag_intent_get( struct xfs_mount *mp, - xfs_agnumber_t agno) + xfs_fsblock_t fsbno) { struct xfs_perag *pag; - pag = xfs_perag_get(mp, agno); + pag = xfs_perag_get(mp, XFS_FSB_TO_AGNO(mp, fsbno)); if (!pag) return NULL; |