STABLE14-windows-afsd-service-20051121

improvements to VNOVNODE fix
This commit is contained in:
Jeffrey Altman 2005-12-07 12:02:41 +00:00
parent c106b5ffe6
commit 61f9832c38
2 changed files with 3 additions and 9 deletions

View File

@ -406,17 +406,11 @@ cm_Analyze(cm_conn_t *connp, cm_user_t *userp, cm_req_t *reqp,
cm_scache_t * scp; cm_scache_t * scp;
osi_Log4(afsd_logp, "cm_Analyze passed VNOVNODE cell %u vol %u vn %u uniq %u.", osi_Log4(afsd_logp, "cm_Analyze passed VNOVNODE cell %u vol %u vn %u uniq %u.",
fidp->cell, fidp->volume, fidp->vnode, fidp->unique); fidp->cell, fidp->volume, fidp->vnode, fidp->unique);
#ifdef VNOVNODE_FLUSH_VOLUME
cm_FlushVolume(userp, reqp, fidp->cell, fidp->volume);
#else /* VNOVNODE_FLUSH_FILE */
if (!cm_GetSCache(fidp, &scp, userp, reqp)) { if (!cm_GetSCache(fidp, &scp, userp, reqp)) {
cm_FlushFile(scp, userp, reqp);
#ifdef VNOVNODE_FLUSH_PARENT
cm_FlushParent(scp, userp, reqp); cm_FlushParent(scp, userp, reqp);
#endif /* VNOVNODE_FLUSH_PARENT */ cm_FlushFile(scp, userp, reqp);
cm_ReleaseSCache(scp); cm_ReleaseSCache(scp);
} }
#endif /* VNODE_FLUSH_xxxx */
} else { } else {
osi_Log0(afsd_logp, "cm_Analyze passed VNOVNODE unknown fid."); osi_Log0(afsd_logp, "cm_Analyze passed VNOVNODE unknown fid.");
} }

View File

@ -82,7 +82,7 @@ long cm_FlushFile(cm_scache_t *scp, cm_user_t *userp, cm_req_t *reqp)
lock_ReleaseMutex(&scp->mx); lock_ReleaseMutex(&scp->mx);
lock_ReleaseWrite(&scp->bufCreateLock); lock_ReleaseWrite(&scp->bufCreateLock);
afsi_log("cm_FlushFile scp 0x%x returns error: [%x]",scp, code); osi_Log2(afsd_logp,"cm_FlushFile scp 0x%x returns error: [%x]",scp, code);
return code; return code;
} }
@ -101,7 +101,7 @@ long cm_FlushParent(cm_scache_t *scp, cm_user_t *userp, cm_req_t *reqp)
for (i=0; i<cm_data.hashTableSize; i++) { for (i=0; i<cm_data.hashTableSize; i++) {
for (scp = cm_data.hashTablep[i]; scp; scp = scp->nextp) { for (scp = cm_data.hashTablep[i]; scp; scp = scp->nextp) {
if (cm_FidCmp(&scp->fid, &parent_fid)) { if (!cm_FidCmp(&scp->fid, &parent_fid)) {
cm_HoldSCacheNoLock(scp); cm_HoldSCacheNoLock(scp);
lock_ReleaseWrite(&cm_scacheLock); lock_ReleaseWrite(&cm_scacheLock);