]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs: use xfs_alloc_vextent_this_ag() where appropriate
authorDave Chinner <dchinner@redhat.com>
Tue, 9 May 2023 09:29:57 +0000 (11:29 +0200)
committerCarlos Maiolino <cem@kernel.org>
Wed, 10 May 2023 11:55:57 +0000 (13:55 +0200)
commit04215b9fb594d93112201061d0d3d06cecbc37b4
tree611ecd66b785383f2a477d426af206afcfdd7f76
parentbad76a2c12509ffe69ad9721d746ae2b940532f1
xfs: use xfs_alloc_vextent_this_ag() where appropriate

Source kernel commit: 74c36a8689d3d8ca9d9e96759c9bbf337e049097

Change obvious callers of single AG allocation to use
xfs_alloc_vextent_this_ag(). Drive the per-ag grabbing out to the
callers, too, so that callers with active references don't need
to do new lookups just for an allocation in a context that already
has a perag reference.

The only remaining caller that does single AG allocation through
xfs_alloc_vextent() is xfs_bmap_btalloc() with
XFS_ALLOCTYPE_NEAR_BNO. That is going to need more untangling before
it can be converted cleanly.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
libxfs/xfs_ag.c
libxfs/xfs_alloc.c
libxfs/xfs_alloc.h
libxfs/xfs_bmap.c
libxfs/xfs_bmap_btree.c
libxfs/xfs_ialloc.c
libxfs/xfs_ialloc_btree.c
libxfs/xfs_refcount_btree.c