diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2018-05-31 18:12:10 +0200 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2018-06-01 18:00:16 +0200 |
commit | a0e5c435babd8bb61612d2e4e9b098cacdd825f7 (patch) | |
tree | 53c77620a452f5c8bf0a41cf5005145f5f335507 /fs/xfs/xfs_rtalloc.h | |
parent | xfs: strengthen rtalloc query range checks (diff) | |
download | linux-a0e5c435babd8bb61612d2e4e9b098cacdd825f7.tar.xz linux-a0e5c435babd8bb61612d2e4e9b098cacdd825f7.zip |
xfs: fix xfs_rtalloc_rec units
All the realtime allocation functions deal with space on the rtdev in
units of realtime extents. However, struct xfs_rtalloc_rec confusingly
uses the word 'block' in the name, even though they're really extents.
Fix the naming problem and fix all the unit handling problems in the two
existing users.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Allison Henderson <allison.henderson@oracle.com>
Reviewed-by: Bill O'Donnell <billodo@redhat.com>
Diffstat (limited to 'fs/xfs/xfs_rtalloc.h')
-rw-r--r-- | fs/xfs/xfs_rtalloc.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/fs/xfs/xfs_rtalloc.h b/fs/xfs/xfs_rtalloc.h index dfee3c991155..52632ab727f7 100644 --- a/fs/xfs/xfs_rtalloc.h +++ b/fs/xfs/xfs_rtalloc.h @@ -23,9 +23,14 @@ struct xfs_mount; struct xfs_trans; +/* + * XXX: Most of the realtime allocation functions deal in units of realtime + * extents, not realtime blocks. This looks funny when paired with the type + * name and screams for a larger cleanup. + */ struct xfs_rtalloc_rec { - xfs_rtblock_t ar_startblock; - xfs_rtblock_t ar_blockcount; + xfs_rtblock_t ar_startext; + xfs_rtblock_t ar_extcount; }; typedef int (*xfs_rtalloc_query_range_fn)( |