]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
ukernel: make web enhancements the default
authorDerrick Brashear <shadow@dementix.org>
Wed, 28 Sep 2011 14:11:16 +0000 (10:11 -0400)
committerDerrick Brashear <shadow@dementix.org>
Fri, 7 Oct 2011 17:32:56 +0000 (10:32 -0700)
none of the web enhancements break base functionality,
and they are strictly more functionality; just turn them on everywhere

Reviewed-on: http://gerrit.openafs.org/5509
Tested-by: Derrick Brashear <shadow@dementix.org>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
(cherry picked from commit 80943970b8cfcdf3fc630b25804aebaea228bd73)

Change-Id: I3d8dedcb84bda70bc3183afcb09ca619c5390476
Reviewed-on: http://gerrit.openafs.org/5540
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
src/afs/UKERNEL/afs_usrops.c
src/afs/VNOPS/afs_vnop_access.c
src/afs/VNOPS/afs_vnop_lookup.c
src/afs/afs_osi_pag.c
src/libuafs/Makefile.common.in

index 89135a08c9abf8c920e451c15de166b4c754b018..b66ce5ccc40a8e769d331728b3e19c84272093d6 100644 (file)
@@ -1741,16 +1741,12 @@ uafs_LookupName(char *path, struct usr_vnode *parentVp,
             */
            nextVc = NULL;
            nextVp = NULL;
-#ifdef AFS_WEB_ENHANCEMENTS
            if ((nextPathP != NULL && *nextPathP != '\0') || !no_eval_mtpt)
                code = afs_lookup(VTOAFS(vp), pathP, &nextVc, get_user_struct()->u_cred, 0);
            else
                code =
                    afs_lookup(VTOAFS(vp), pathP, &nextVc, get_user_struct()->u_cred,
                               AFS_LOOKUP_NOEVAL);
-#else
-           code = afs_lookup(VTOAFS(vp), pathP, &nextVc, get_user_struct()->u_cred, 0);
-#endif /* AFS_WEB_ENHANCEMENTS */
            if (nextVc)
                nextVp=AFSTOV(nextVc);
            if (code != 0) {
@@ -3612,7 +3608,6 @@ uafs_afsPathName(char *path)
     return NULL;
 }
 
-#ifdef AFS_WEB_ENHANCEMENTS
 /*
  * uafs_klog_nopag
  * klog but don't allocate a new pag
@@ -3788,6 +3783,4 @@ uafs_getRights(char *path)
     AFS_GUNLOCK();
     return afs_rights;
 }
-#endif /* AFS_WEB_ENHANCEMENTS */
-
 #endif /* UKERNEL */
index eabcfebe2b0dbb48dde7abd87f3c7d343a75c28b..feb0ca7a4f5b707a34b833a9c66fe94bc4c0d638 100644 (file)
@@ -332,7 +332,7 @@ afs_access(OSI_VC_DECL(avc), afs_int32 amode,
     }
 }
 
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
 /*
  * afs_getRights
  * This function is just an interface to afs_GetAccessBits
@@ -356,4 +356,4 @@ afs_getRights(OSI_VC_DECL(avc), afs_int32 arights,
 
     return afs_GetAccessBits(avc, arights, &treq);
 }
-#endif /* defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS) */
+#endif /* defined(UKERNEL) */
index 3559d9b24a2a0ad6105747e63804440ed7e2341f..2e575c1e8831cbafdfb05741bdb6353cc2af4e6e 100644 (file)
@@ -1752,10 +1752,10 @@ afs_lookup(OSI_VC_DECL(adp), char *aname, struct vcache **avcp, afs_ucred_t *acr
        if (tvc->mvstat == 1 && (tvc->f.states & CMValid) && tvc->mvid != NULL)
          force_eval = 1; /* This is now almost for free, get it correct */
 
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
        if (!(flags & AFS_LOOKUP_NOEVAL))
            /* don't eval mount points */
-#endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+#endif /* UKERNEL */
            if (tvc->mvstat == 1 && force_eval) {
                /* a mt point, possibly unevaluated */
                struct volume *tvolp;
@@ -1863,13 +1863,13 @@ afs_lookup(OSI_VC_DECL(adp), char *aname, struct vcache **avcp, afs_ucred_t *acr
        if (afs_mariner)
            afs_AddMarinerName(aname, tvc);
 
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
        if (!(flags & AFS_LOOKUP_NOEVAL)) {
            /* Here we don't enter the name into the DNLC because we want the
             * evaluated mount dir to be there (the vcache for the mounted
             * volume) rather than the vc of the mount point itself.  We can
             * still find the mount point's vc in the vcache by its fid. */
-#endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+#endif /* UKERNEL */
            if (!hit && force_eval) {
                osi_dnlc_enter(adp, aname, tvc, &versionNo);
            } else {
@@ -1882,7 +1882,7 @@ afs_lookup(OSI_VC_DECL(adp), char *aname, struct vcache **avcp, afs_ucred_t *acr
                return 0;       /* can't have been any errors if hit and !code */
 #endif
            }
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
        }
 #endif
     }
index c888605354d6c225db5547cbd1299eb88255444d..20cee62a9e2c65b43ae502b46e2038471903374d 100644 (file)
@@ -36,11 +36,11 @@ extern int afs_shuttingdown;
 
 /* Exported variables */
 afs_uint32 pag_epoch;
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
 afs_uint32 pagCounter = 1;
 #else
 afs_uint32 pagCounter = 0;
-#endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+#endif /* UKERNEL */
 
 #ifdef AFS_LINUX26_ONEGROUP_ENV
 #define NUMPAGGROUPS 1
@@ -73,7 +73,7 @@ afs_uint32 pagCounter = 0;
  * anyway, so the pag is an alternative handle which is somewhat more
  * secure (although of course not absolutely secure).
 */
-#if !defined(UKERNEL) || !defined(AFS_WEB_ENHANCEMENTS)
+#if !defined(UKERNEL)
 afs_uint32
 genpag(void)
 {
@@ -125,7 +125,7 @@ getpag(void)
     return (pagCounter);
 #endif
 }
-#endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+#endif /* UKERNEL */
 
 /* used to require 10 seconds between each setpag to guarantee that
  * PAGs never wrap - which would be a security hole.  If we presume
@@ -291,7 +291,7 @@ afs_setpag(void)
     return (code);
 }
 
-#if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+#if defined(UKERNEL)
 /*
  * afs_setpag_val
  * This function is like setpag but sets the current thread's pag id to a
@@ -414,7 +414,7 @@ afs_getpag_val(void)
     return pagvalue;
 }
 #endif
-#endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+#endif /* UKERNEL */
 
 
 /* Note - needs to be available on AIX, others can be static - rework this */
@@ -504,13 +504,13 @@ afs_get_pag_from_groups(gid_t g0a, gid_t g1a)
        h = (g0 >> 14);
        h = (g1 >> 14) + h + h + h;
        ret = ((h << 28) | l);
-# if defined(UKERNEL) && defined(AFS_WEB_ENHANCEMENTS)
+# if defined(UKERNEL)
        return ret;
 # else
        /* Additional testing */
        if (((ret >> 24) & 0xff) == 'A')
            return ret;
-# endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+# endif /* UKERNEL */
     }
     return NOPAG;
 }
@@ -523,9 +523,9 @@ afs_get_groups_from_pag(afs_uint32 pag, gid_t * g0p, gid_t * g1p)
     AFS_STATCNT(afs_get_groups_from_pag);
     *g0p = pag;
     *g1p = 0;
-# if !defined(UKERNEL) || !defined(AFS_WEB_ENHANCEMENTS)
+# if !defined(UKERNEL)
     pag &= 0x7fffffff;
-# endif /* UKERNEL && AFS_WEB_ENHANCEMENTS */
+# endif /* UKERNEL */
     g0 = 0x3fff & (pag >> 14);
     g1 = 0x3fff & pag;
     g0 |= ((pag >> 28) / 3) << 14;
index fe3acc1c8728c7277ad667ba2d725996b0f6de06..d20ac86d8a8d763195201c3d32cca612be2e1b08 100644 (file)
@@ -1560,7 +1560,7 @@ UAFS/$(LIBUAFS): setup_uafs
 
 JUAFS/$(LIBJUAFS): setup_juafs
        cd JUAFS && \
-       $(MAKE) $(LIBJUAFS) DESTDIR=${DESTDIR} LIBJUAFS_FLAGS=-DAFS_WEB_ENHANCEMENTS && \
+       $(MAKE) $(LIBJUAFS) DESTDIR=${DESTDIR} LIBJUAFS_FLAGS=&& \
        $(RANLIB) $(LIBJUAFS)
 
 AFSWEB/$(LIBAFSWEB): setup_nsafs