xfs: refactor xfs_log_force_lsn
authorChristoph Hellwig <hch@lst.de>
Wed, 14 Mar 2018 06:15:29 +0000 (23:15 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Sat, 24 Mar 2018 01:05:06 +0000 (18:05 -0700)
commit93806299b56b22df8fec9b78cb4c9c41d283ee2a
tree9734db3a6d3388e87b749347485195f9eb1c3976
parentdf79b81b2e6a801c134c3e06c647715a316b4a92
xfs: refactor xfs_log_force_lsn

Use the the smallest possible loop as preable to find the correct iclog
buffer, and then use gotos for unwinding to straighten the code.

Also fix the top of function comment while we're at it.

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