]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
xfs: remove unnecessary dfops init calls in xattr code
authorBrian Foster <bfoster@redhat.com>
Fri, 5 Oct 2018 02:36:10 +0000 (21:36 -0500)
committerEric Sandeen <sandeen@redhat.com>
Fri, 5 Oct 2018 02:36:10 +0000 (21:36 -0500)
commit82d7af89102ee70528c36de2443dc408b22b361b
tree43d05d9abb0ab9b48ac3ae9e5858c95d2264d7d5
parent29ae66ebd62799f211f9bdba72966d98b0bf4d9a
xfs: remove unnecessary dfops init calls in xattr code

Source kernel commit: d5cca7eb244d276177a57e42494d479742bbba37

Each xfs_defer_init() call in the xattr code uses the internal dfops
reference. In addition, a successful xfs_defer_finish() always
returns with a reset xfs_defer_ops structure.

Given that along with the fact that every xfs_defer_init() call in
the xattr code is followed up by an xfs_defer_finish(), the former
calls are no longer necessary and can be removed.

Note that the xfs_defer_init() call in the remote value copy loop of
xfs_attr_rmtval_set() is not followed by a finish, but the dfops is
unused in this instance.

Signed-off-by: Brian Foster <bfoster@redhat.com>
Reviewed-by: Bill O'Donnell <billodo@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>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_attr.c
libxfs/xfs_attr_remote.c