#define PIGGYSIZE 1350 /* max piggyback size */
#define MAXVOLS 128 /* max vols we can store */
#define MAXSYSNAME 128 /* max sysname (i.e. @sys) size */
-#define MAXNUMSYSNAMES 16 /* max that current constants allow */
+#define MAXNUMSYSNAMES 32 /* max that current constants allow */
#define NOTOKTIMEOUT (2*3600) /* time after which to timeout conns sans tokens */
#define NOPAG 0xffffffff
#define AFS_NCBRS 300 /* max # of call back return entries */
#if defined(AFS_CACHE_BYPASS)
#define BOP_FETCH_NOCACHE 4 /* parms are: vnode ptr, offset, segment ptr, addr, cred ptr */
#endif
+#ifdef AFS_DARWIN_ENV
+#define BOP_MOVE 5 /* ptr1 afs_uspc_param ptr2 sname ptr3 dname */
+#endif
#define B_DONTWAIT 1 /* On failure return; don't wait */
*/
#define TMP_UPAGNotReferenced 128
+/* unixuser notify events */
+#define UTokensObtained 1
+#define UTokensDropped 2
+
/* values for afs_gcpags */
enum { AFS_GCPAGS_NOTCOMPILED = 0, AFS_GCPAGS_OK =
1, AFS_GCPAGS_USERDISABLED, AFS_GCPAGS_EPROC0, AFS_GCPAGS_EPROCN,
#define SRVR_ISGONE 0x80
#define SNO_INLINEBULK 0x100
#define SNO_64BIT 0x200
+#define SCAPS_KNOWN 0x400
+
+#define SRV_CAPABILITIES(ts) \
+{ if ( !(ts->flags & SCAPS_KNOWN)) afs_GetCapabilities(ts); ts->capabilities; }
#define afs_serverSetNo64Bit(s) ((s)->srvr->server->flags |= SNO_64BIT)
#define afs_serverHasNo64Bit(s) ((s)->srvr->server->flags & SNO_64BIT)
afs_int32 sumOfDowntimes; /* Total downtime experienced, in seconds */
struct srvAddr *addr;
afs_uint32 flags; /* Misc flags */
+ afs_int32 capabilities;
};
#define afs_PutServer(servp, locktype)
#define CVFlushed 0x00080000
#ifdef AFS_LINUX22_ENV
#define CPageWrite 0x00200000 /* to detect vm deadlock - linux */
-#else
+#elif defined(AFS_SGI_ENV)
#define CWritingUFS 0x00200000 /* to detect vm deadlock - used by sgi */
+#elif defined(AFS_DARWIN80_ENV)
+#define CEvent 0x00200000 /* to preclude deadlock when sending events */
#endif
#define CCreating 0x00400000 /* avoid needless store after open truncate */
#define CPageHog 0x00800000 /* AIX - dumping large cores is a page hog. */
#endif
#endif
+#if SIZEOF_VOID_P == SIZEOF_UNSIGNED_INT
+# define uintptrsz unsigned int
+#elif SIZEOF_VOID_P == SIZEOF_UNSIGNED_LONG
+# define uintptrsz unsigned long
+#elif SIZEOF_VOID_P == SIZEOF_UNSIGNED_LONG_LONG
+# define uintptrsz unsigned long long
+#else
+# error "Unable to determine casting for pointers"
+#endif
+
struct afs_ioctl {
uparmtype in; /* input buffer */
uparmtype out; /* output buffer */
#if defined(AFS_CACHE_VNODE_PATH)
typedef char *afs_ufs_dcache_id_t;
-#elif defined(UKERNEL)
-typedef afs_int32 afs_ufs_dcache_id_t;
#elif defined(AFS_SGI61_ENV) || defined(AFS_SUN57_64BIT_ENV)
/* Using ino64_t here so that user level debugging programs compile
* the size correctly.
#ifndef afs_vnodeToDev
#if defined(AFS_SGI62_ENV) || defined(AFS_HAVE_VXFS) || defined(AFS_DARWIN_ENV)
#define afs_vnodeToDev(V) VnodeToDev(V)
+#elif defined(UKERNEL)
+#define afs_vnodeToDev(V) (VTOI(V) ? (VTOI(V)->i_dev) : (-1))
#else
#define afs_vnodeToDev(V) (VTOI(V)->i_dev)
#endif