xfs: xfs_defer_capture should absorb remaining transaction reservation
authorDarrick J. Wong <darrick.wong@oracle.com>
Sat, 26 Sep 2020 00:39:50 +0000 (17:39 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Wed, 7 Oct 2020 15:40:28 +0000 (08:40 -0700)
commit929b92f64048d90d23e40a59c47adf59f5026903
treeeaa5a37bc81ac188e9df697679be6374398b996d
parent4f9a60c48078c0efa3459678fa8d6e050e8ada5d
xfs: xfs_defer_capture should absorb remaining transaction reservation

When xfs_defer_capture extracts the deferred ops and transaction state
from a transaction, it should record the transaction reservation type
from the old transaction so that when we continue the dfops chain, we
still use the same reservation parameters.

Doing this means that the log item recovery functions get to determine
the transaction reservation instead of abusing tr_itruncate in yet
another part of xfs.

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