]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs: return if_data from xfs_idata_realloc
authorChristoph Hellwig <hch@lst.de>
Mon, 15 Apr 2024 23:07:42 +0000 (16:07 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 17 Apr 2024 21:06:26 +0000 (14:06 -0700)
commit4ff35b84151b75ca428a34b57a1bc02db976b5af
tree57f547991232434bb73d5892a4ac5b774f71baee
parentf814619757c33c0952680093adfc5285d32dc701
xfs: return if_data from xfs_idata_realloc

Source kernel commit: 45c76a2add55b332d965c901e14004ae0134a67e

Many of the xfs_idata_realloc callers need to set a local pointer to the
just reallocated if_data memory.  Return the pointer to simplify them a
bit and use the opportunity to re-use krealloc for freeing if_data if the
size hits 0.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Chandan Babu R <chandanbabu@kernel.org>
Reviewed-by: Bill O'Donnell <bodonnel@redhat.com>
libxfs/xfs_attr_leaf.c
libxfs/xfs_dir2_sf.c
libxfs/xfs_inode_fork.c
libxfs/xfs_inode_fork.h