• Dave Chinner's avatar
    xfs: merge _xfs_buf_get_pages() · 02c51173
    Dave Chinner authored
    Only called from one place now, so merge it into
    xfs_buf_alloc_pages(). Because page array allocation is dependent on
    bp->b_pages being null, always ensure that when the pages array is
    freed we always set bp->b_pages to null.
    
    Also convert the page array to use kmalloc() rather than
    kmem_alloc() so we can use the gfp flags we've already calculated
    for the allocation context instead of hard coding KM_NOFS semantics.
    Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
    Reviewed-by: default avatarDarrick J. Wong <djwong@kernel.org>
    02c51173
xfs_buf.c 57.4 KB