• Andreas Gruenbacher's avatar
    gfs2: Fix metadata read-ahead during truncate · c3ce5aa9
    Andreas Gruenbacher authored
    The metadata read-ahead algorithm broke when switching from recursive to
    non-recursive delete: the current algorithm reads ahead blocks at height
    N - 1 while deallocating the blocks at hight N.  However, deallocating
    the blocks at height N requires a complete walk of the metadata tree,
    not only down to height N - 1.  Consequently, all blocks below height
    N - 1 will be accessed without read-ahead.
    
    Fix this by issuing read-aheads as early as possible, after each
    metapath lookup.
    Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
    Signed-off-by: default avatarBob Peterson <rpeterso@redhat.com>
    c3ce5aa9
bmap.c 49.2 KB