diff options
Diffstat (limited to 'sys/miscfs/union/union.h')
-rw-r--r-- | sys/miscfs/union/union.h | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/sys/miscfs/union/union.h b/sys/miscfs/union/union.h index 9c740d3..c956921 100644 --- a/sys/miscfs/union/union.h +++ b/sys/miscfs/union/union.h @@ -34,7 +34,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * @(#)union.h 8.2 (Berkeley) 2/17/94 + * @(#)union.h 8.9 (Berkeley) 12/10/94 * $FreeBSD$ */ @@ -75,10 +75,14 @@ struct union_node { struct vnode *un_uppervp; /* overlaying object */ struct vnode *un_lowervp; /* underlying object */ struct vnode *un_dirvp; /* Parent dir of uppervp */ + struct vnode *un_pvp; /* Parent vnode */ char *un_path; /* saved component name */ int un_hash; /* saved un_path hash value */ int un_openl; /* # of opens on lowervp */ - int un_flags; + unsigned int un_flags; + struct vnode **un_dircache; /* cached union stack */ + off_t un_uppersz; /* size of upper object */ + off_t un_lowersz; /* size of lower object */ #ifdef DIAGNOSTIC pid_t un_pid; #endif @@ -88,16 +92,23 @@ struct union_node { #define UN_LOCKED 0x02 #define UN_ULOCK 0x04 /* Upper node is locked */ #define UN_KLOCK 0x08 /* Keep upper node locked on vput */ +#define UN_CACHED 0x10 /* In union cache */ extern int union_allocvp __P((struct vnode **, struct mount *, struct vnode *, struct vnode *, struct componentname *, struct vnode *, - struct vnode *)); + struct vnode *, int)); extern int union_freevp __P((struct vnode *)); -extern int union_copyfile __P((struct proc *, struct ucred *, - struct vnode *, struct vnode *)); +extern int union_copyfile __P((struct vnode *, struct vnode *, + struct ucred *, struct proc *)); +extern int union_copyup __P((struct union_node *, int, struct ucred *, + struct proc *)); +extern int union_dowhiteout __P((struct union_node *, struct ucred *, + struct proc *)); extern int union_mkshadow __P((struct union_mount *, struct vnode *, struct componentname *, struct vnode **)); +extern int union_mkwhiteout __P((struct union_mount *, struct vnode *, + struct componentname *, char *)); extern int union_vn_create __P((struct vnode **, struct union_node *, struct proc *)); extern int union_vn_close __P((struct vnode *, int, struct ucred *, @@ -108,6 +119,7 @@ extern void union_removed_upper __P((struct union_node *un)); extern struct vnode *union_lowervp __P((struct vnode *)); extern void union_newlower __P((struct union_node *, struct vnode *)); extern void union_newupper __P((struct union_node *, struct vnode *)); +extern void union_newsize __P((struct vnode *, off_t, off_t)); #define MOUNTTOUNIONMOUNT(mp) ((struct union_mount *)((mp)->mnt_data)) #define VTOUNION(vp) ((struct union_node *)(vp)->v_data) |