From ef08d58e9361ca72b22bff091c870dbcae6ab1f1 Mon Sep 17 00:00:00 2001 From: Chaskiel M Grundman Date: Wed, 13 Oct 2004 01:36:59 +0000 Subject: [PATCH] linux-26-vlru-cycle-20041012 FIXES 15339 it was only a matter of time... --- src/afs/afs_vcache.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/afs/afs_vcache.c b/src/afs/afs_vcache.c index 87c467f16..249e27228 100644 --- a/src/afs/afs_vcache.c +++ b/src/afs/afs_vcache.c @@ -840,9 +840,18 @@ afs_NewVCache(struct VenusFid *afid, struct server *serverp) #elif defined(AFS_LINUX22_ENV) if (tvc != afs_globalVp && VREFCOUNT(tvc) && tvc->opens == 0) { #if defined(AFS_LINUX26_ENV) - AFS_GUNLOCK(); - d_prune_aliases(AFSTOI(tvc)); - AFS_GLOCK(); + struct dentry *dentry; + struct list_head *cur, *head = &(AFSTOI(tvc))->i_dentry; + AFS_GUNLOCK(); + cur=head; + while ((cur = cur->next) != head) { + dentry = list_entry(cur, struct dentry, d_alias); + if (!d_unhashed(dentry) && + !list_empty(&dentry->d_subdirs)) + shrink_dcache_parent(dentry); + } + d_prune_aliases(AFSTOI(tvc)); + AFS_GLOCK(); #else afs_TryFlushDcacheChildren(tvc); #endif -- 2.39.5