"i think this was missed from a patch i sent a while back to cleanup
the iput() of afs inodes. i think the lock(vc->lock) needs to be in
osi_clear_inode() since osi_clear_inode is called a bit more often
than afs_delete_inode(). however, this like just might be uneeded
since no one has seen any problems apparently."
#endif
printf("afs_put_inode: ino %d (0x%x) has count %d\n", ip->i_ino, ip);
+ ObtainWriteLock(&vc->lock, 504);
afs_InactiveVCache(vc, credp);
+ ReleaseWriteLock(&vc->lock);
#if defined(AFS_LINUX24_ENV)
atomic_set(&ip->i_count, 0);
#else
if (!ip->i_count)
#endif
osi_clear_inode(ip);
- AFS_GUNLOCK();
}
- else {
- AFS_GUNLOCK();
+ else
iput(ip);
- }
+ AFS_GUNLOCK();
}
/* check_bad_parent() : Checks if this dentry's vcache is a root vcache
struct vcache *vc = (struct vcache*)ip;
AFS_GLOCK();
- ObtainWriteLock(&vc->lock, 504);
osi_clear_inode(ip);
- ReleaseWriteLock(&vc->lock);
AFS_GUNLOCK();
}