Windows: GiveUpAllCallBacks only if non-loopback
authorJeffrey Altman <jaltman@your-file-system.com>
Wed, 30 Oct 2013 04:44:25 +0000 (00:44 -0400)
committerJeffrey Altman <jaltman@your-file-system.com>
Sat, 16 Nov 2013 00:58:25 +0000 (16:58 -0800)
If the only ip addresses are known to be loopback addresses, then
do not waste time by attempting to GiveUpAllCallBacks during suspend
or shutdown.

Change-Id: I28b08e61435a7132ba08c9649010185097df0da0
Reviewed-on: http://gerrit.openafs.org/10429
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>

src/WINNT/afsd/cm_scache.c

index 1745e6d..a619428 100644 (file)
@@ -689,7 +689,8 @@ cm_SuspendSCache(void)
     cm_scache_t * scp;
     time_t now;
 
-    cm_GiveUpAllCallbacksAllServersMulti(TRUE);
+    if (!lana_OnlyLoopback())
+       cm_GiveUpAllCallbacksAllServersMulti(TRUE);
 
     /*
      * After this call all servers are marked down.
@@ -725,7 +726,8 @@ cm_ShutdownSCache(void)
 {
     cm_scache_t * scp, * nextp;
 
-    cm_GiveUpAllCallbacksAllServersMulti(FALSE);
+    if (!lana_OnlyLoopback())
+       cm_GiveUpAllCallbacksAllServersMulti(FALSE);
 
     lock_ObtainWrite(&cm_scacheLock);