• Andreas Gruenbacher's avatar
    gfs2: Make sure we don't miss any delayed withdraws · 5a61ae14
    Andreas Gruenbacher authored
    Commit ca399c96 changes gfs2_log_flush to not withdraw the
    filesystem while holding the log flush lock, but it fails to check if
    the filesystem needs to be withdrawn once the log flush lock has been
    released.  Likewise, commit f05b86db depends on gfs2_log_flush to
    trigger for delayed withdraws.  Add that and clean up the code flow
    somewhat.
    
    In gfs2_put_super, add a check for delayed withdraws that have been
    missed to prevent these kinds of bugs in the future.
    
    Fixes: ca399c96 ("gfs2: flesh out delayed withdraw for gfs2_log_flush")
    Fixes: f05b86db ("gfs2: Prepare to withdraw as soon as an IO error occurs in log write")
    Cc: stable@vger.kernel.org # v5.7+: 462582b9: gfs2: add some much needed cleanup for log flushes that fail
    Signed-off-by: default avatarAndreas Gruenbacher <agruenba@redhat.com>
    5a61ae14
util.h 6.17 KB