diff options
| author | Christoph Hellwig <hch@lst.de> | 2024-12-21 08:38:28 +0000 |
|---|---|---|
| committer | Christoph Hellwig <hch@lst.de> | 2025-03-03 08:16:44 -0700 |
| commit | 012482b3308a49a84c2a7df08218dd4ad081e1da (patch) | |
| tree | 6bccb1d5d02040be5aca0c8e0620d93e6908a810 /fs/xfs/libxfs/xfs_rtgroup.h | |
| parent | a581de0d613aa810c020edc1ea576c75fa5b3950 (diff) | |
xfs: add a rtg_blocks helper
Shortcut dereferencing the xg_block_count field in the generic group
structure.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Diffstat (limited to 'fs/xfs/libxfs/xfs_rtgroup.h')
| -rw-r--r-- | fs/xfs/libxfs/xfs_rtgroup.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_rtgroup.h b/fs/xfs/libxfs/xfs_rtgroup.h index 03f39d4e43fc..9c7e03f913cb 100644 --- a/fs/xfs/libxfs/xfs_rtgroup.h +++ b/fs/xfs/libxfs/xfs_rtgroup.h @@ -66,6 +66,11 @@ static inline xfs_rgnumber_t rtg_rgno(const struct xfs_rtgroup *rtg) return rtg->rtg_group.xg_gno; } +static inline xfs_rgblock_t rtg_blocks(const struct xfs_rtgroup *rtg) +{ + return rtg->rtg_group.xg_block_count; +} + static inline struct xfs_inode *rtg_bitmap(const struct xfs_rtgroup *rtg) { return rtg->rtg_inodes[XFS_RTGI_BITMAP]; |
