Re: [PATCH 06/20] xfs: don't use REQ_PREFLUSH for split log writes

Dave Chinner
2019-05-23T22:39:30Z

On Thu, May 23, 2019 at 07:37:28PM +0200, Christoph Hellwig wrote:
> If we have to split a log write because it wraps the end of the log we
> can't just use REQ_PREFLUSH to flush before the first log write,
> as the writes might get reordered somewhere in the I/O stack. Issue
> a manual flush in that case so that the ordering of the two log I/Os
> doesn't matter.
>
> Signed-off-by: Christoph Hellwig <hch@lst.de>

Yup, we clear the flush flag from the second buffer so this is
actually necessary. Very subtle, nice catch.

Reviewed-by: Dave Chinner <dchinner@redhat.com>
--
Dave Chinner
david@fromorbit.com