/* clear the permit cache on a directory vnode  */
void afs_clear_permits(struct afs_vnode *vnode)
/* clear the permit cache on a directory vnode  */
void afs_clear_permits(struct afs_vnode *vnode)
{
	struct afs_permits *permits;
	_enter("{%x:%u}", vnode->fid.vid, vnode->fid.vnode);
	mutex_lock(&vnode->permits_lock);
	permits = vnode->permits;
	rcu_assign_pointer(vnode->permits, NULL);
	mutex_unlock(&vnode->permits_lock);
	if (permits)
		call_rcu(&permits->rcu, afs_zap_permits);
	_leave("");
}