• Dave Chinner's avatar
    xfs: introduce xfs_alloc_vextent_prepare() · 74b9aa63
    Dave Chinner authored
    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: default avatarDave Chinner <dchinner@redhat.com>
    Reviewed-by: default avatarDarrick J. Wong <djwong@kernel.org>
    74b9aa63
xfs_alloc.c 101 KB