FreeBSD/sys/ufs/ufs/ufs_extattr.c
/*
 * Called by UFS when an inode is no longer active and should have its
 * attributes stripped.
 */
Called by UFS when an inode is no longer active and should have its
attributes stripped.
Called by UFS when an inode is no longer active and should have its attributes stripped .
void
ufs_extattr_vnode_inactive(struct vnode *vp, struct thread *td)
{
	struct ufs_extattr_list_entry *uele;
	struct mount *mp = vp->v_mount;
	struct ufsmount *ump = VFSTOUFS(mp);
	if (!(ump->um_extattr.uepm_flags & UFS_EXTATTR_UEPM_INITIALIZED))
		return;
	ufs_extattr_uepm_lock(ump);
	if (!(ump->um_extattr.uepm_flags & UFS_EXTATTR_UEPM_STARTED)) {
		ufs_extattr_uepm_unlock(ump);
		return;
	}
	LIST_FOREACH(uele, &ump->um_extattr.uepm_list, uele_entries)
		ufs_extattr_rm(vp, uele->uele_attrnamespace,
		    uele->uele_attrname, NULL, td);
	ufs_extattr_uepm_unlock(ump);
}
void ufs_extattr_vnode_inactive ( struct vnode * vp , struct thread * td ) { struct ufs_extattr_list_entry * uele ; struct mount * mp = vp -> v_mount ; struct ufsmount * ump = VFSTOUFS ( mp ) ; if ( ! ( ump -> um_extattr . uepm_flags & UFS_EXTATTR_UEPM_INITIALIZED ) ) return ; ufs_extattr_uepm_lock ( ump ) ; if ( ! ( ump -> um_extattr . uepm_flags & UFS_EXTATTR_UEPM_STARTED ) ) { ufs_extattr_uepm_unlock ( ump ) ; return ; } LIST_FOREACH ( uele , & ump -> um_extattr . uepm_list , uele_entries ) ufs_extattr_rm ( vp , uele -> uele_attrnamespace , uele -> uele_attrname , NULL , td ) ; ufs_extattr_uepm_unlock ( ump ) ; }
Called by UFS when an inode is no longer active and should have its
 attributes stripped.
Called by UFS when an inode is no longer active and should have its attributes stripped .
/*
	 * In that case, we cannot lock. We should not have any active vnodes
	 * on the fs if this is not yet initialized but is going to be, so
	 * this can go unlocked.
	 */