afs: Delete unneeded duplicate code
[openafs.git] / src / afs / afs_call.c
index aebc567..4e3c4c4 100644 (file)
@@ -10,6 +10,9 @@
 #include <afsconfig.h>
 #include "afs/param.h"
 
+#if defined(HAVE_LINUX_KTHREAD_RUN) && !defined(UKERNEL)
+#  include "h/kthread.h"
+#endif
 
 #include "afs/sysincludes.h"   /* Standard vendor system headers */
 #include "afsincludes.h"       /* Afs-based standard headers */
@@ -25,9 +28,6 @@
 #   include "netinet/in_var.h"
 #  endif
 # endif
-# ifdef HAVE_LINUX_KTHREAD_RUN
-#  include "h/kthread.h"
-# endif
 #endif /* !defined(UKERNEL) */
 #ifdef AFS_SUN510_ENV
 #include "h/ksynch.h"
@@ -77,6 +77,7 @@ static int afs_InitSetup_done = 0;
 afs_int32 afs_numcachefiles = -1;
 afs_int32 afs_numfilesperdir = -1;
 char afs_cachebasedir[1024];
+afs_int32 afs_rmtsys_enable = 0;
 
 afs_int32 afs_rx_deadtime = AFS_RXDEADTIME;
 afs_int32 afs_rx_harddead = AFS_HARDDEADTIME;
@@ -1053,10 +1054,6 @@ afs_syscall_call(long parm, long parm2, long parm3,
        code = 0;
        AFS_COPYINSTR(AFSKPTR(parm2), tbuffer, AFS_SMALLOCSIZ, &bufferSize,
                      code);
-       if (code) {
-           osi_FreeSmallSpace(tbuffer);
-           goto out;
-       }
        if (!code) {
            tbuffer[AFS_SMALLOCSIZ - 1] = '\0'; /* null-terminate the name */
            /* We have the cache dir copied in.  Call the cache init routine */
@@ -1314,6 +1311,9 @@ afs_syscall_call(long parm, long parm2, long parm3,
        rx_MyMaxSendSize = rx_maxReceiveSizeUser = rx_maxReceiveSize = parm2;
     } else if (parm == AFSOP_SET_RXMAXFRAGS) {
        rxi_nSendFrags = rxi_nRecvFrags = parm2;
+    } else if (parm == AFSOP_SET_RMTSYS_FLAG) {
+       afs_rmtsys_enable = parm2;
+       code = 0;
     } else {
        code = EINVAL;
     }