1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-11-22 07:20:00 +00:00
freebsd/sys/fs/unionfs
Jason A. Harmening 2ed053cde5 vfs: Add IGNOREWHITEOUT flag and adopt it in UFS/unionfs
This flag is meant to request that the VOP implementation ignore
whiteout entries when processing directory contents.

Employ this flag (initially) in UFS when determining whether a directory
is empty for the purpose of deleting it or renaming another directory
over it.  The previous UFS behavior was to always ignore whiteouts and
to therefore always allow directories containing only whiteouts to be
deleted or overwritten.  This makes sense when the directory in question
is being accessed through a unionfs view in which the whiteouts produce
a unionfs directory that is logically empty, but it makes less sense
when directly operating against the UFS directory in which case silently
discarding the whiteouts may produce unexpected behavior in a current or
future unionfs view.  IGNOREWHITEOUT is therefore treated as opt-in and
only specified by unionfs_rmdir() when invoking VOP_RMDIR() against the
upper filesystem.  IGNOREWHITEOUT is not currently used for unionfs
rename operations, as the current implementation of unionfs_rename()
simply forbids renaming over any existing upper filesystem directory in
the first place.

Differential Revision:	https://reviews.freebsd.org/D45987
Reviewed by:		olce
Tested by:		pho
2024-09-08 18:34:14 -05:00
..
union_subr.c unionfs: fix LINT build 2024-07-12 22:41:17 -05:00
union_vfsops.c unionfs: rework locking scheme to only lock a single vnode 2024-07-12 17:05:16 -05:00
union_vnops.c vfs: Add IGNOREWHITEOUT flag and adopt it in UFS/unionfs 2024-09-08 18:34:14 -05:00
union.h unionfs: do not create a new status object during vop_close() 2024-07-12 17:05:16 -05:00