]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
xfs: distinguish extra split from real ENOSPC from xfs_attr_node_try_addname
authorChristoph Hellwig <hch@lst.de>
Mon, 21 Oct 2024 00:10:47 +0000 (17:10 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 31 Oct 2024 22:45:03 +0000 (15:45 -0700)
commit1f246811849bb773e95cb1fbe89ed965b5e2d8a8
tree1023a13dc7e3ff204dacddfed2e8f200aeb971d2
parent2089fbfedcde9c62d67f53913e47c99303be1d87
xfs: distinguish extra split from real ENOSPC from xfs_attr_node_try_addname

Source kernel commit: b3f4e84e2f438a119b7ca8684a25452b3e57c0f0

Just like xfs_attr3_leaf_split, xfs_attr_node_try_addname can return
-ENOSPC both for an actual failure to allocate a disk block, but also
to signal the caller to convert the format of the attr fork.  Use magic
1 to ask for the conversion here as well.

Note that unlike the similar issue in xfs_attr3_leaf_split, this one was
only found by code review.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
libxfs/xfs_attr.c