]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
xfs: better xfs_trans_alloc interface
authorChristoph Hellwig <hch@lst.de>
Tue, 21 Jun 2016 23:32:40 +0000 (09:32 +1000)
committerDave Chinner <david@fromorbit.com>
Tue, 21 Jun 2016 23:32:40 +0000 (09:32 +1000)
commit9074815cd478613b8aaf756c5e21d4ee5f1e5b95
tree879468ec74eba47460fabeff80c66e4778662474
parent4cab415fc9e9b7d7b365c2e222b90b88a3053f01
xfs: better xfs_trans_alloc interface

Source kernel commit 253f4911f297b83745938b7f2c5649b94730b002

Merge xfs_trans_reserve and xfs_trans_alloc into a single function call
that returns a transaction with all the required log and block reservations,
and which allows passing transaction flags directly to avoid the cumbersome
_xfs_trans_alloc interface.

While we're at it we also get rid of the transaction type argument that has
been superflous since we stopped supporting the non-CIL logging mode.  The
guts of it will be removed in another patch.

[dchinner: fixed transaction leak in error path in xfs_setattr_nonsize]

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
14 files changed:
include/xfs_trans.h
libxfs/libxfs_api_defs.h
libxfs/libxfs_priv.h
libxfs/trans.c
libxfs/util.c
libxfs/xfs_attr.c
libxfs/xfs_bmap.c
libxfs/xfs_sb.c
libxfs/xfs_shared.h
mkfs/proto.c
mkfs/xfs_mkfs.c
repair/phase5.c
repair/phase6.c
repair/phase7.c