gfs2: Additional information when gfs2_ail1_flush withdraws
authorBob Peterson <rpeterso@redhat.com>
Fri, 6 Mar 2020 16:15:03 +0000 (10:15 -0600)
committerBob Peterson <rpeterso@redhat.com>
Fri, 6 Mar 2020 16:15:03 +0000 (10:15 -0600)
Before this patch, if gfs2_ail1_flush gets an error from function
gfs2_ail1_start_one (which comes indirectly from generic_writepages)
the file system is withdrawn, but without any explanation why.

This patch adds an error message if gfs2_ail1_flush gets an error
from gfs2_ail1_start_one.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
fs/gfs2/log.c

index 67465a34954eecdfec55133df11f4429c124ab98..87f3e892be3e8fa46d8c0b7f19d3ecc3de37fb9f 100644 (file)
@@ -172,8 +172,11 @@ restart:
        }
        spin_unlock(&sdp->sd_ail_lock);
        blk_finish_plug(&plug);
-       if (ret)
+       if (ret) {
+               gfs2_lm(sdp, "gfs2_ail1_start_one (generic_writepages) "
+                       "returned: %d\n", ret);
                gfs2_withdraw(sdp);
+       }
        trace_gfs2_ail_flush(sdp, wbc, 0);
 }