 mntput(xdmnt); dput(xdentry); 
path_release(&old_nd); 
void mark_mounts_for_expiry(struct list_head *mounts){	struct namespace *namespace;	struct vfsmount *mnt, *next;	LIST_HEAD(graveyard);	if (list_empty(mounts))		return;	spin_lock(&vfsmount_lock);	/* extract from the expiration list every vfsmount that matches the	 * following criteria:	 * - only referenced by its parent vfsmount	 * - still marked for expiry (marked on the last call here; marks are	 *   cleared by mntput())	 */	list_for_each_entry_safe(mnt, next, mounts, mnt_fslink) {		if (!xchg(&mnt->mnt_expiry_mark, 1) ||		    atomic_read(&mnt->mnt_count) != 1)			continue;		mntget(mnt);		list_move(&mnt->mnt_fslink, &graveyard);	}	/*	 * go through the vfsmounts we've just consigned to the graveyard to	 * - check that they're still dead	 * - delete the vfsmount from the appropriate namespace under lock	 * - dispose of the corpse	 */	while (!list_empty(&graveyard)) {		mnt = list_entry(graveyard.next, struct vfsmount, mnt_fslink);		list_del_init(&mnt->mnt_fslink);		/* don't do anything if the namespace is dead - all the		 * vfsmounts from it are going away anyway */		namespace = mnt->mnt_namespace;		if (!namespace || !namespace->root)			continue;		get_namespace(namespace);		spin_unlock(&vfsmount_lock);		down_write(&namespace->sem);		spin_lock(&vfsmount_lock);		/* check that it is still dead: the count should now be 2 - as		 * contributed by the vfsmount parent and the mntget above */		if (atomic_read(&mnt->mnt_count) == 2) {			struct vfsmount *xdmnt;			struct dentry *xdentry;			/* delete from the namespace */			list_del_init(&mnt->mnt_list);			list_del_init(&mnt->mnt_child);			list_del_init(&mnt->mnt_hash);			mnt->mnt_mountpoint->d_mounted--;			xdentry = mnt->mnt_mountpoint;			mnt->mnt_mountpoint = mnt->mnt_root;			xdmnt = mnt->mnt_parent;			mnt->mnt_parent = mnt;			spin_unlock(&vfsmount_lock);			mntput(xdmnt);			dput(xdentry);			/* now lay it to rest if this was the last ref on the			 * superblock */			if (atomic_read(&mnt->mnt_sb->s_active) == 1) {				/* last instance - try to be smart */				lock_kernel();				DQUOT_OFF(mnt->mnt_sb);				acct_auto_close(mnt->mnt_sb);				unlock_kernel();			}			mntput(mnt);		} else {			/* someone brought it back to life whilst we didn't			 * have any locks held so return it to the expiration			 * list */			list_add_tail(&mnt->mnt_fslink, mounts);			spin_unlock(&vfsmount_lock);		}		up_write(&namespace->sem);		mntput(mnt);		put_namespace(namespace);		spin_lock(&vfsmount_lock);	}	spin_unlock(&vfsmount_lock);}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/a4d70278610e6bebe44a7b59a469fe7391387da6/namespace.c/buggy/fs/namespace.c