From: Andreas Gruenbacher Date: Wed, 1 Apr 2026 16:18:38 +0000 (+0200) Subject: gfs2: drain ail under sd_log_flush_lock X-Git-Tag: v7.1-rc1~137^2~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7d2da6ed172680a7ef06acfe3e44a2326977573f;p=thirdparty%2Fkernel%2Flinux.git gfs2: drain ail under sd_log_flush_lock When a withdraw is carried out, call gfs2_ail_drain() under the sdp->sd_log_flush_lock. This isn't strictly necessary but should be easier to read, and more robust against possible future bugs. Signed-off-by: Andreas Gruenbacher --- diff --git a/fs/gfs2/util.c b/fs/gfs2/util.c index 02603200846d6..83b8bb6446e57 100644 --- a/fs/gfs2/util.c +++ b/fs/gfs2/util.c @@ -123,9 +123,8 @@ static void do_withdraw(struct gfs2_sbd *sdp) return; } clear_bit(SDF_JOURNAL_LIVE, &sdp->sd_flags); - up_write(&sdp->sd_log_flush_lock); - gfs2_ail_drain(sdp); /* frees all transactions */ + up_write(&sdp->sd_log_flush_lock); wake_up(&sdp->sd_logd_waitq); wake_up(&sdp->sd_quota_wait);