]> git.apps.os.sepia.ceph.com Git - xfsprogs-dev.git/commit
xfs: condense symbolic links after a mapping exchange operation
authorDarrick J. Wong <djwong@kernel.org>
Mon, 29 Jul 2024 23:22:36 +0000 (16:22 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Tue, 30 Jul 2024 00:00:59 +0000 (17:00 -0700)
commit6898c1eb181102ef1d580ee9d390182e77ef3a0f
tree0021bdd17a12492a222899463c5fadd4265a00e7
parentfd6e011de53f2c7397088ea567a4edb678d15c5b
xfs: condense symbolic links after a mapping exchange operation

Source kernel commit: 33a9be2b7016e79f47c4c1b523a0aa59d41893c0

The previous commit added a new file mapping exchange flag that enables
us to perform post-exchange processing on file2 once we're done
exchanging the extent mappings.  Now add this ability for symlinks.

This isn't used anywhere right now, but we need to have the basic ondisk
flags in place so that a future online symlink repair feature can
salvage the remote target in a temporary link and exchange the data fork
mappings when ready.  If one file is in extents format and the other is
inline, we will have to promote both to extents format to perform the
exchange.  After the exchange, we can try to condense the fixed symlink
down to inline format if possible.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
libxfs/xfs_exchmaps.c
libxfs/xfs_symlink_remote.c
libxfs/xfs_symlink_remote.h