diff options
author | daichi <daichi@FreeBSD.org> | 2007-10-14 13:46:11 +0000 |
---|---|---|
committer | daichi <daichi@FreeBSD.org> | 2007-10-14 13:46:11 +0000 |
commit | a009cf6b3cb242d382411f28b524c2271f3eae0a (patch) | |
tree | d179467b6c3f66e075aa75cdd47a26a6ef2ef6cd /sys/fs/unionfs/union.h | |
parent | 4aad1608ad423bcbfccc18e26294a44fdedd723a (diff) | |
download | FreeBSD-src-a009cf6b3cb242d382411f28b524c2271f3eae0a.zip FreeBSD-src-a009cf6b3cb242d382411f28b524c2271f3eae0a.tar.gz |
- Added support for vfs_cache on unionfs. As a result, you can use
applications that use procfs on unionfs.
- Removed unionfs internal cache mechanism because it has
vfs_cache support instead. As a result, it just simplified code of
unionfs.
- Fixed kern/111262 issue.
Submitted by: Masanori Ozawa <ozawa@ongs.co.jp> (unionfs developer)
Reviewed by: jeff, kensmith
Approved by: re (kensmith)
MFC after: 1 week
Diffstat (limited to 'sys/fs/unionfs/union.h')
-rw-r--r-- | sys/fs/unionfs/union.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/sys/fs/unionfs/union.h b/sys/fs/unionfs/union.h index e2df553..302b384 100644 --- a/sys/fs/unionfs/union.h +++ b/sys/fs/unionfs/union.h @@ -72,7 +72,6 @@ struct unionfs_node_status { /* A cache of vnode references */ struct unionfs_node { - LIST_ENTRY(unionfs_node) un_hash; /* Hash list */ struct vnode *un_lowervp; /* lower side vnode */ struct vnode *un_uppervp; /* upper side vnode */ struct vnode *un_dvp; /* parent unionfs vnode */ @@ -82,10 +81,12 @@ struct unionfs_node { int un_flag; /* unionfs node flag */ }; -/* unionfs node flags */ -#define UNIONFS_CACHED 0x01 /* is cached */ -#define UNIONFS_OPENEXTL 0x02 /* openextattr (lower) */ -#define UNIONFS_OPENEXTU 0x04 /* openextattr (upper) */ +/* + * unionfs node flags + * It needs the vnode with exclusive lock, when changing the un_flag variable. + */ +#define UNIONFS_OPENEXTL 0x01 /* openextattr (lower) */ +#define UNIONFS_OPENEXTU 0x02 /* openextattr (upper) */ #define MOUNTTOUNIONFSMOUNT(mp) ((struct unionfs_mount *)((mp)->mnt_data)) #define VTOUNIONFS(vp) ((struct unionfs_node *)(vp)->v_data) @@ -94,7 +95,7 @@ struct unionfs_node { int unionfs_init(struct vfsconf *vfsp); int unionfs_uninit(struct vfsconf *vfsp); int unionfs_nodeget(struct mount *mp, struct vnode *uppervp, struct vnode *lowervp, struct vnode *dvp, struct vnode **vpp, struct componentname *cnp, struct thread *td); -void unionfs_hashrem(struct vnode *vp, struct thread *td); +void unionfs_noderem(struct vnode *vp, struct thread *td); void unionfs_get_node_status(struct unionfs_node *unp, struct thread *td, struct unionfs_node_status **unspp); void unionfs_tryrem_node_status(struct unionfs_node *unp, struct thread *td, struct unionfs_node_status *unsp); |