xfs: factor out a xlog_wait_on_iclog helper
authorChristoph Hellwig <hch@lst.de>
Fri, 20 Mar 2020 15:49:18 +0000 (08:49 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Mon, 23 Mar 2020 15:27:58 +0000 (08:27 -0700)
commit81e5b50a8fb5a2865ede48f6012a0bb9b9136cdc
treec8f1b0dd64b174d1ce09f6bf394ff906a35a10dc
parentc7cc296ddd1f6d15d0e9490da89c7dbe6e0d752d
xfs: factor out a xlog_wait_on_iclog helper

Factor out the shared code to wait for a log force into a new helper.
This helper uses the XLOG_FORCED_SHUTDOWN check previous only used
by the unmount code over the equivalent iclog ioerror state used by
the other two functions.

There is a slight behavior change in that the force of the unmount
record is now accounted in the log force statistics.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
fs/xfs/xfs_log.c