]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: move log iovec alignment to preparation function
authorDave Chinner <dchinner@redhat.com>
Thu, 21 Apr 2022 00:34:49 +0000 (10:34 +1000)
committerDave Chinner <david@fromorbit.com>
Thu, 21 Apr 2022 00:34:49 +0000 (10:34 +1000)
commite8c1cf88f8e6a3d11bf13edb21e0de358155d584
tree9e400a4e78164afc8eca7976c9392d21058069aa
parent60e8b3ca2763f5821d80d05931bfa5667e09b3d8
xfs: move log iovec alignment to preparation function

To include log op headers directly into the log iovec regions that
the ophdrs wrap, we need to move the buffer alignment code from
xlog_finish_iovec() to xlog_prepare_iovec(). This is because the
xlog_op_header is only 12 bytes long, and we need the buffer that
the caller formats their data into to be 8 byte aligned.

Hence once we start prepending the ophdr in xlog_prepare_iovec(), we
are going to need to manage the padding directly to ensure that the
buffer pointer returned is correctly aligned.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Chandan Babu R <chandan.babu@oracle.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
fs/xfs/xfs_log.h