• Darrick J. Wong's avatar
    xfs: create a sparse load xfarray function · 5a3ab584
    Darrick J. Wong authored
    Create a new method to load an xfarray element from the xfile, but with
    a twist.  If we've never stored to the array index, zero the caller's
    buffer.  This will facilitate RMWs updates of records in a sparse array
    without fuss, since the sparse xfarray convention is that uninitialized
    array elements default to zeroes.
    
    This is a separate patch to reduce the size of the upcoming quotacheck
    patch.
    Signed-off-by: default avatarDarrick J. Wong <djwong@kernel.org>
    Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
    5a3ab584
xfarray.h 5.05 KB