]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Windows: Add registry entries for rx_SetMinPeerTimeout, rx_SetMaxRecvWindow, rx_SetMa...
authorJeffrey Altman <jaltman@secure-endpoints.com>
Wed, 21 Oct 2009 13:14:51 +0000 (09:14 -0400)
committerJeffrey Altman <jaltman|account-1000011@unknown>
Wed, 21 Oct 2009 18:03:43 +0000 (11:03 -0700)
Permit the new rx settings to be configured via the registry and
set at startup.

LICENSE MIT

Reviewed-on: http://gerrit.openafs.org/700
Tested-by: Jeffrey Altman <jaltman@openafs.org>
Reviewed-by: Jeffrey Altman <jaltman@openafs.org>
src/WINNT/afsd/afsd_init.c

index d9f85f348f3d5b180a774afda614e4e91703e86f..8760ccde5f1ee49316765c89d0b0883d2760f23e 100644 (file)
@@ -500,6 +500,9 @@ afsd_InitCM(char **reasonP)
     long maxcpus;
     long ltt, ltto;
     long rx_nojumbo;
+    int  rx_max_rwin_size;
+    int  rx_max_swin_size;
+    int  rx_min_peer_timeout;
     long virtualCache = 0;
     fschar_t rootCellName[256];
     struct rx_service *serverp;
@@ -1016,6 +1019,27 @@ afsd_InitCM(char **reasonP)
     }
     afsi_log("SMB authentication type is %s", ((smb_authType == SMB_AUTH_NONE)?"NONE":((smb_authType == SMB_AUTH_EXTENDED)?"EXTENDED":"NTLM")));
 
+    dummyLen = sizeof(rx_max_rwin_size);
+    code = RegQueryValueEx(parmKey, "RxMaxRecvWinSize", NULL, NULL,
+                           (BYTE *) &rx_max_rwin_size, &dummyLen);
+    if (code == ERROR_SUCCESS)
+        rx_SetMaxReceiveWindow(rx_max_rwin_size);
+    afsi_log("Rx Maximum Receive Window Size is %d", rx_GetMaxReceiveWindow());
+
+    dummyLen = sizeof(rx_max_swin_size);
+    code = RegQueryValueEx(parmKey, "RxMaxSendWinSize", NULL, NULL,
+                           (BYTE *) &rx_max_swin_size, &dummyLen);
+    if (code == ERROR_SUCCESS)
+        rx_SetMaxSendWindow(rx_max_swin_size);
+    afsi_log("Rx Maximum Send Window Size is %d", rx_GetMaxSendWindow());
+
+    dummyLen = sizeof(rx_min_peer_timeout);
+    code = RegQueryValueEx(parmKey, "RxMinPeerTimeout", NULL, NULL,
+                           (BYTE *) &rx_min_peer_timeout, &dummyLen);
+    if (code == ERROR_SUCCESS)
+        rx_SetMinPeerTimeout(rx_min_peer_timeout);
+    afsi_log("Rx Minimum Peer Timeout is %d ms", rx_GetMinPeerTimeout());
+
     dummyLen = sizeof(rx_nojumbo);
     code = RegQueryValueEx(parmKey, "RxNoJumbo", NULL, NULL,
                            (BYTE *) &rx_nojumbo, &dummyLen);