]> asedeno.scripts.mit.edu Git - linux.git/commit
xfs: add firstblock field to xfs_trans
authorBrian Foster <bfoster@redhat.com>
Thu, 12 Jul 2018 05:26:20 +0000 (22:26 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Thu, 12 Jul 2018 05:26:20 +0000 (22:26 -0700)
commitbba59c5e4b38e160c6be25b2f4fe36ebc84f53df
treecdf16ceb3bf16bbc31b104d010ca714bd529afd1
parent3ae2d89174e4ba581093320afb48421ca95191d2
xfs: add firstblock field to xfs_trans

A firstblock var is typically allocated and initialized along with
xfs_defer_ops structures and passed around independent from the
associated transaction. To facilitate combining the two, add an
optional ->t_firstblock field to xfs_trans that can be used in place
of an on-stack variable.

The firstblock value follows the lifetime of the transaction, so
initialize it on allocation and when a transaction rolls.

Signed-off-by: Brian Foster <bfoster@redhat.com>
Reviewed-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_trans.c
fs/xfs/xfs_trans.h