gfs2: drain the ail2 list after io errors
authorBob Peterson <rpeterso@redhat.com>
Wed, 13 Nov 2019 19:58:30 +0000 (13:58 -0600)
committerBob Peterson <rpeterso@redhat.com>
Thu, 27 Feb 2020 13:53:18 +0000 (07:53 -0600)
commit2ca0c2fbf3ed7f9609333a996149d02f70e8a6f3
tree9d889f9dbf31be4cd97776eb99f97056eca09716
parentb1676cbb11153b5bf4dd9e6c99869b284fb8160e
gfs2: drain the ail2 list after io errors

Before this patch, gfs2_logd continually tried to flush its journal
log, after the file system is withdrawn. We don't want to write anything
to the journal, lest we add corruption. Best course of action is to
drain the ail1 into the ail2 list (via gfs2_ail1_empty) then drain the
ail2 list with a new function, ail2_drain.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Reviewed-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/log.c
fs/gfs2/trans.c