} else {
afs_warn("BYPASS: StartRXAFS_FetchData failed: %d\n", code);
unlock_and_release_pages(auio);
- afs_PutConn(tc, rxconn, SHARED_LOCK);
+ (void)afs_Analyze(tc, rxconn, code, &avc->f.fid, areq,
+ AFS_STATS_FS_RPCIDX_FETCHDATA,
+ SHARED_LOCK, NULL);
goto done;
}
if (code == 0) {
afs_warn("BYPASS: No connection.\n");
code = -1;
unlock_and_release_pages(auio);
+ (void)afs_Analyze(tc, rxconn, code, &avc->f.fid, areq,
+ AFS_STATS_FS_RPCIDX_FETCHDATA,
+ SHARED_LOCK, NULL);
goto done;
}
} while (afs_Analyze(tc, rxconn, code, &avc->f.fid, areq,
ReleaseWriteLock(&tdc->lock);
afs_PutDCache(tdc);
tdc = 0;
- ReleaseReadLock(&avc->lock);
- if (tc) {
- /* If we have a connection, we must put it back,
- * since afs_Analyze will not be called here. */
- afs_PutConn(tc, rxconn, SHARED_LOCK);
- }
+ /*
+ * Call afs_Analyze to manage the connection references
+ * and handle the error code (possibly mark servers
+ * down, etc). We are going to retry getting the
+ * dcache regardless, so we just ignore the retry hint
+ * returned by afs_Analyze on this call.
+ */
+ (void)afs_Analyze(tc, rxconn, code, &avc->f.fid, areq,
+ AFS_STATS_FS_RPCIDX_FETCHDATA, SHARED_LOCK, NULL);
+
+ ReleaseReadLock(&avc->lock);
slowPass = 1;
goto RetryGetDCache;