NetBSD/sys/ufs
hannken 72439b7dc8 Current support for iterating over mnt_vnodelist is rudimentary. Every
caller has to care about list and vnode mutexes, reference count being zero,
intermediate vnode states like VI_CLEAN, VI_XLOCK, VI_MARKER and so on.

Add an interface to iterate over a vnode list:

void vfs_vnode_iterator_init(struct mount *mp, struct vnode_iterator **marker)
void vfs_vnode_iterator_destroy(struct vnode_iterator *marker)
bool vfs_vnode_iterator_next(struct vnode_iterator *marker, struct vnode **vpp)

vfs_vnode_iterator_next() returns either "false / *vpp == NULL" when done
or "true / *vpp != NULL" to return the next referenced vnode from the list.

To make vrecycle() work in this environment change it to

bool vrecycle(struct vnode *vp)

where "vp" is a referenced vnode to be destroyed if this is the last reference.

Discussed on tech-kern.

Welcome to 6.99.34
2014-03-05 09:37:29 +00:00
..
chfs The current implementation of vn_lock() is racy. Modification of 2014-02-27 16:51:37 +00:00
ext2fs Current support for iterating over mnt_vnodelist is rudimentary. Every 2014-03-05 09:37:29 +00:00
ffs Current support for iterating over mnt_vnodelist is rudimentary. Every 2014-03-05 09:37:29 +00:00
lfs Current support for iterating over mnt_vnodelist is rudimentary. Every 2014-03-05 09:37:29 +00:00
mfs Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist before 2014-02-25 18:30:08 +00:00
ufs The current implementation of vn_lock() is racy. Modification of 2014-02-27 16:51:37 +00:00
Makefile
files.ufs Collect the pieces of lfs rename into lfs_rename.c, and sprinkle static. 2013-07-20 19:59:31 +00:00