mirror_zfs/include/os/linux/zfs/sys
Aleksa Sarai dbf6108b4d zfs_rename: support RENAME_* flags
Implement support for Linux's RENAME_* flags (for renameat2). Aside from
being quite useful for userspace (providing race-free ways to exchange
paths and implement mv --no-clobber), they are used by overlayfs and are
thus required in order to use overlayfs-on-ZFS.

In order for us to represent the new renameat2(2) flags in the ZIL, we
create two new transaction types for the two flags which need
transactional-level support (RENAME_EXCHANGE and RENAME_WHITEOUT).
RENAME_NOREPLACE does not need any ZIL support because we know that if
the operation succeeded before creating the ZIL entry, there was no file
to be clobbered and thus it can be treated as a regular TX_RENAME.

Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Pavel Snajdr <snajpa@snajpa.net>
Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
Closes #12209
Closes #14070
2022-10-28 09:49:20 -07:00
..
policy.h Support idmapped mount 2022-10-19 11:17:09 -07:00
sha2.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_acl.h Remove zpl_revalidate: fix snapshot rollback 2022-10-28 09:47:19 -07:00
trace_arc.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_common.h Fix zio_flag_t print format 2022-10-28 09:08:12 -07:00
trace_dbgmsg.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_dbuf.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_dmu.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_dnode.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_multilist.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_rrwlock.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_txg.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_vdev.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_zfs.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_zil.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_zio.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
trace_zrlock.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
zfs_bootenv_os.h zfs label bootenv should store data as nvlist 2020-09-15 15:42:27 -07:00
zfs_context_os.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
zfs_ctldir.h Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
zfs_dir.h zfs_rename: restructure to have cleaner fallbacks 2022-10-28 09:48:58 -07:00
zfs_vfsops_os.h Retire ZFS_TEARDOWN_TRY_ENTER_READ 2022-09-20 15:34:41 -07:00
zfs_vnops_os.h zfs_rename: support RENAME_* flags 2022-10-28 09:49:20 -07:00
zfs_znode_impl.h zfs_enter rework 2022-09-16 13:36:47 -07:00
zpl.h zfs_rename: support RENAME_* flags 2022-10-28 09:49:20 -07:00