RXOSD and VICEP-ACCESS fields and bits in afs.h
authorHartmut Reuter <reuter@rzg.mpg.de>
Fri, 5 Nov 2010 10:31:28 +0000 (11:31 +0100)
committerDerrick Brashear <shadow@dementia.org>
Mon, 15 Nov 2010 17:50:11 +0000 (09:50 -0800)
struct vcache gets two new fields:
int protocol
        which in the lower 16 bits contains the protocol number
                1 classical rx-fileserver,
                2 rxosd,
                4 direct access to visible vicep partitions.
void *vpacRock
        which for visible files in a vicep-partition contains
        a pointer to a struct known only inside afs_vicep.c
        which contains the pointer to the open file and other
        information.

Change-Id: I9d471a010d99bfa53ac59be3e7daad72e29d02ee
Reviewed-on: http://gerrit.openafs.org/3013
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>

src/afs/afs.h

index e755d59..037edf1 100644 (file)
@@ -530,6 +530,7 @@ struct chservinfo {
 #define VResort         16     /* server order was rearranged, sort when able */
 #define VMoreReps       32     /* This volume has more replicas than we are   */
                             /* keeping track of now -- check with VLDB     */
+#define VPartVisible   64      /* Volume's partition is visible on the client */
 
 enum repstate { not_busy, end_not_busy = 6, rd_busy, rdwr_busy, offline };
 
@@ -621,6 +622,7 @@ struct SimpleLocks {
 #define CExtendedFile  0x08000000      /* extended file via ftruncate call. */
 #define CVInit          0x10000000      /* being initialized */
 #define CMetaDirty     0x20000000      /* vnode meta-data needs to be flushed */
+#define CPartVisible   0x40000000      /* fileserver partition visible on client */
 
 /* vcache vstate bits */
 #define VRevokeWait   0x1
@@ -877,6 +879,10 @@ struct vcache {
 #ifdef AFS_SUN5_ENV
     short multiPage;           /* count of multi-page getpages in progress */
 #endif
+    int protocol;              /* RX_FILESERVER, RX_OSD, ... defined in afsint.xg */
+#if !defined(UKERNEL)
+    void *vpacRock;            /* used to read or write in visible partitions */
+#endif
 };
 
 #define        DONT_CHECK_MODE_BITS    0
@@ -1309,6 +1315,7 @@ extern struct brequest afs_brs[NBRS];     /* request structures */
 
 #define        AFS_FSPORT          ((unsigned short) htons(7000))
 #define        AFS_VLPORT          ((unsigned short) htons(7003))
+#define AFS_RXOSDPORT      ((unsigned short) htons(7011))
 
 #define        afs_read(avc, uio, acred, albn, abpp, nolock) \
         (*(afs_cacheType->vread))(avc, uio, acred, albn, abpp, nolock)