/* Try to prune ancestors as well. This is necessary to prevent quadratic behavior of shrink_dcache_parent(), but is also expected to be beneficial in reducing dentry cache fragmentation.  */
static void prune_one_dentry(struct dentry *dentry) __releases(dentry -> d_lock) __releases(dcache_lock) __acquires(dcache_lock)
/* Try to prune ancestors as well. This is necessary to prevent quadratic behavior of shrink_dcache_parent(), but is also expected to be beneficial in reducing dentry cache fragmentation.  */
static void prune_one_dentry(struct dentry *dentry) __releases(dentry -> d_lock) __releases(dcache_lock) __acquires(dcache_lock)
{
	__d_drop(dentry);
	dentry = d_kill(dentry);
	spin_lock(&dcache_lock);
	while (dentry) {
		if (!atomic_dec_and_lock(&dentry->d_count, &dentry->d_lock))
			return;
		if (dentry->d_op && dentry->d_op->d_delete)
			dentry->d_op->d_delete(dentry);
		dentry_lru_del_init(dentry);
		__d_drop(dentry);
		dentry = d_kill(dentry);
		spin_lock(&dcache_lock);
	}
}