mirror of
https://github.com/torvalds/linux.git
synced 2024-11-14 16:12:02 +00:00
a26dc21309
Once we've assembled all the parent pointers for a file, we need to commit the new dataset atomically to that file. Parent pointer records are embedded in the xattr structure, which means that we must write a new extended attribute structure, again, atomically. Therefore, we must copy the non-parent-pointer attributes from the file being repaired into the temporary file's extended attributes and then call the atomic extent swap mechanism to exchange the blocks. Signed-off-by: Darrick J. Wong <djwong@kernel.org> Reviewed-by: Christoph Hellwig <hch@lst.de>
16 lines
470 B
C
16 lines
470 B
C
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
/*
|
|
* Copyright (c) 2018-2024 Oracle. All Rights Reserved.
|
|
* Author: Darrick J. Wong <djwong@kernel.org>
|
|
*/
|
|
#ifndef __XFS_SCRUB_ATTR_REPAIR_H__
|
|
#define __XFS_SCRUB_ATTR_REPAIR_H__
|
|
|
|
struct xrep_tempexch;
|
|
|
|
int xrep_xattr_swap(struct xfs_scrub *sc, struct xrep_tempexch *tx);
|
|
int xrep_xattr_reset_fork(struct xfs_scrub *sc);
|
|
int xrep_xattr_reset_tempfile_fork(struct xfs_scrub *sc);
|
|
|
|
#endif /* __XFS_SCRUB_ATTR_REPAIR_H__ */
|