]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs: introduce xfs_alloc_vextent_prepare()
authorDave Chinner <dchinner@redhat.com>
Tue, 9 May 2023 09:30:28 +0000 (11:30 +0200)
committerCarlos Maiolino <cem@kernel.org>
Wed, 10 May 2023 12:31:21 +0000 (14:31 +0200)
commita74b5502183248592ab6f84b2432a5e7c9212a62
tree88a3249bf70f18c2f591c5f0bf131d5ce7a9c1c3
parentc4e10f2b0807d62ae50f48405b7e98104f1a6ee6
xfs: introduce xfs_alloc_vextent_prepare()

Source kernel commit: 74b9aa63193b288191d6f01b61c819cef2807138

Now that we have wrapper functions for each type of allocation we
can ask for, we can start unravelling xfs_alloc_ag_vextent(). That
is essentially just a prepare stage, the allocation multiplexer
and a post-allocation accounting step is the allocation proceeded.

The current xfs_alloc_vextent*() wrappers all have a prepare stage,
the allocation operation and a post-allocation accounting step.

We can consolidate this by moving the AG alloc prep code into the
wrapper functions, the accounting code in the wrapper accounting
functions, and cut out the multiplexer layer entirely.

This patch consolidates the AG preparation stage.

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_alloc.c